Returns the path of the data model root.
Page model root path.
Checks if the currently open app in aem editor is a remote app
true if remote app
Add the given callback as a listener for changes at the given path.
Absolute path of the resource (e.g., "/content/mypage"). If not provided, the root page path is used.
Function to be executed listening to changes at given path.
Returns the model for the given configuration.
Model object for specific path.
Initializes the ModelManager using the given path to resolve a data model. If no path is provided, fallbacks are applied in the following order:
cq:pagemodel_root_url
If page model does not contain information about current path it performs additional fetch.
Initializes the ModelManager asynchronously using the given path to resolve a data model. Ideal use case would be for remote apps which do not need the page model to be passed down from the root. For remote apps with no model path, an empty store is initialized and data is fetched on demand by components.
Once the initial model is loaded and if the data model doesn't contain the path of the current pathname, the library attempts to fetch a fragment of model.
Root model path is resolved in the following order of preference:
cq:pagemodel_root_url
Remove the callback listener from the given path path.
Absolute path of the resource (e.g., "/content/mypage"). If not provided, the root page path is used.
Listener function to be removed.
Generated using TypeDoc
ModelManager is main entry point of this module.
Example:
Boostrap:
index.html
Bootstrap:
index.js
For asynchronous loading of root model/standalone item model
For root model, custom event is fired on window with fetched model - cq-pagemodel-loaded