-
Notifications
You must be signed in to change notification settings - Fork 0
Home
jobdk edited this page Mar 22, 2021
·
8 revisions
- View names are capitalized
- All views are stored in the view folder
- Names of XML views always end with *.view.xml
- The default XML namespace is sap.m
- Other XML namespaces use the last part of the SAP namespace as alias (for example, mvc for sap.ui.core.mvc)
- Controller names are capitalized
- Controllers carry the same name as the related view (if there is a 1:1 relationship)
- Event handlers are prefixed with on
- Controller names always end with *.controller.js
- The resource model for internationalization is called the i18n model.
- The default filename is i18n.properties.
- Resource bundle keys are written in (lower) camelCase.
- Resource bundle values can contain parameters like {0}, {1}, {2}, …
- Never concatenate strings that are translated, always use placeholders.
- Use Unicode escape sequences for special characters.
- The component is named Component.js.
- Together with all UI assets of the app, the component is located in the webapp folder.
- The index.html file is located in the webapp folder if it is used productively.
- Do not specify colors in custom CSS but use the standard theme-dependent classes instead
##Testing
- All unit tests are placed in the webapp/test/unit folder of the app.
- Files in the test suite end with *.qunit.html.
- The unitTests.qunit.html file triggers all unit tests of the app.
- A unit test should be written for formatters, controller logic, and other individual functionality.
- All dependencies are replaced by stubs to test only the functionality in scope.