Best Practices
The widely accepted standard for a given procedure is known as a best practice as it produces the optimal results. In the ES asset extension model the following best practices are followed for naming conventions and jaggery modules.
Naming Conventions
This section describes the naming convention best practices that are recommended when naming different aspects in ES.
App and extension naming |
Example: store-common
|
Variable naming | All code and extensions in ES conforms to the camel case naming convention. |
Commenting | ES and the related modules conform to the JSDoc commenting specifications when commenting. |
Reusable code | Code segments being shared across pages or api endpoints should be collected into a javascript module and imported using the respective syntax accordingly. |
Â
Jaggery modules
This section describes the different jaggery modules used for asset extensions, which is in the <ES_HOME>/modules
 folder.
rxt module | The
|
lifecycle module | The
|
utils module | The util module provides the following functions and objects:Â
|
store module | The store module provides the following utility methods:
|