Helpers.common Class
Access point: ac.helpers.* Addon that provides helpers functionalities
Methods
expose
(
-
helperName -
helper
Expose a helper function as global. On the server side this means any mojit instance under a particular request can use the helper. On the client, any mojit instance on the page can use the helper.
Parameters:
-
helperNameStringThe helper name.
-
helperFunctionOptional helper function, if not present, the helper will be lookup by name.
get
(
Function | Object
-
helperName
Gets one specific helper if the name is specified, otherwise returns all available helpers.
Parameters:
-
helperNameStringThe optional helper name
Returns:
Function | Object:
a helper function or all available helpers
set
(
-
helperName -
helper
set a helper function at the mojit instance.
Parameters:
-
helperNameStringThe helper name.
-
helperFunctionThe helper function.
