]> git.evergreen-ils.org Git - working/Evergreen.git/blob - Open-ILS/src/eg2/CHEAT_SHEET.adoc
LP#1775466 Angular(6) base application
[working/Evergreen.git] / Open-ILS / src / eg2 / CHEAT_SHEET.adoc
1 = Evergreen Angular App Cheatsheet
2
3 == Basics
4
5 [source,sh]
6 ---------------------------------------------------------------------
7 npm update
8 npm install
9 ng lint             # check code formatting
10 npm run test        # unit tests
11 ng build --watch    # compile dev mode
12 ng build --prod     # compile production mode
13 ---------------------------------------------------------------------
14
15 == OPTIONAL: Adding a Locale 
16
17 * Using fr-CA as an example.
18 * An fr-CA configuration is supplied by default.  Additional configs
19   must be added where needed.
20 * Currently translation builds are only available on --prod build mode.
21 * Uncomment the locale lines in eg_vhost.conf and restart apache.
22 * TODO: expand docs on package.json file changes required to add locales.
23
24 [source,sh]
25 ---------------------------------------------------------------------
26 npm run export-strings
27 npm run merge-strings -- fr-CA
28 # APPLY TRANSLATIONS TO src/locale/messages.fr-CA.xlf
29 npm run build-fr-CA # modify package.json for other locales
30 ---------------------------------------------------------------------
31