@antiraid-ext/framework/storage
API reference for @antiraid-ext/framework/storage
@antiraid-ext/framework/storage
Functions
get
Upvalue to store the framework
Returns the current framework instance if it exists.
If it does not exist, returns nil.
Function Signature
-- Upvalue to store the framework
--- Returns the current framework instance if it exists.
--- If it does not exist, returns nil.
function get() -> coretypes.Framework? end
Returns
ret1
set
Sets the framework instance.
If it is already set, it will throw an error.
Function Signature
--- Sets the framework instance.
--- If it is already set, it will throw an error.
function set(framework: coretypes.Framework) end
Arguments
framework
replace
Replaces any current framework instance with a new one.
Unlike set, this does not throw an error if the framework is already set.
Function Signature
--- Replaces any current framework instance with a new one.
--- Unlike set, this does not throw an error if the framework is already set.
function replace(newFramework: coretypes.Framework) end
Arguments
newFramework
share
Helper method to share a framework with all other templates.
Function Signature
--- Helper method to share a framework with all other templates.
function share(ctx: Primitives.TemplateContext, framework: coretypes.Framework) end
Arguments
ctx
framework
getShared
Helper method to return all shared frameworks.
Function Signature
--- Helper method to return all shared frameworks.
function getShared(ctx: Primitives.TemplateContext) -> {
[string]: coretypes.Framework
} end
Arguments
ctx
Returns
ret1
Last updated on