Admin interface for managing DreamFactory instance.
- Node.js >=16.14.0
- Angular CLI
npm install
husky is used to run git hooks for formatting and linting checking code prior to commiting code. To install husky run the following command:
npm run prepare
npm start
Proxying to DreamFactory instance is configured in proxy.conf.json.
npm run lint
npm run lint:fix
npm run prettier
jest is used for unit testing. Tests are named with the following convention: [name].spec.ts
npm run test
npm run test:watch
npm run test:coverage
npm run build
When more than one language is supported, the language selector will be displayed in the top right corner of the application.
-
User language will be detected from preference provided by browser. If browser preference is a supported language it will be selected by default.
-
If language selector is enabled and user change language manually, their preference is stored in
localStorage
for future reference. If language preference is found inlocalStorage
, than it is treated as default language. -
To add a new language, follow these steps:
- Add a new entry to the
SUPPORTED_LANGUAGES
array in src/app/shared/constants/languages.ts.- code: The language code. This is used to identify the language in the application.
- altCode: Alternative language code that might be provided by browser. eg en-US, en-CA.
- Create new translation files in src/assets/i18n and every sub-folder.
- Ensure label for languages are created in alternative language in src/assets/i18n/en.json
"languages": { "en": "English" }
- These are used to display language label in dropdown.
- Ensure label for languages are created in alternative language in src/assets/i18n/en.json
- Add a new entry to the