molalla-fm.odata-lib
v0.0.0
Published
This as an angular multi project currently consisting of three sub-projects:
Downloads
2
Readme
This as an angular multi project currently consisting of three sub-projects:
- mfm-odata-lib
- MolallaFM.Client
- Website.Client
Build mfm-odata-lib
To build the library, cd into projects/mfm-odata-lib
and run ng build
if you are deploying or ng build --watch
if you are doing development.
Build MolallaFM.Client
To build the web version, cd into projects/MolallaFM.Client
and run ng build --base-href /MolallaFM.WebApi/ --outputHashing=all
. When that finishes, run the deploy.sh -f
script from the Server project to rsync what was built from projects/MolallaFM.Client/www
folder to the MolallaFM.WebApi/wwwroot
folder on autoprov. After deploying, send an email to MSR and NetworkOperations asking them to clear their cache, so they get the new version of the client. Note that the --outputHashing=all
option is what tells the compiler to generate unique names for everything so that the end-user doesn't have to clear their cache to get the new version.
To build the mobile version, on a mac, you run ionic capacitor copy ios
to build and copy the assets into the ios folder. Then run ionic capacitor open ios
which will open the project in xcode. Plug the phone or ipad into the machine running xcode with a lightning or usb-c cable and choose Product->Destination->DeviceName. Then choose Product->Run and xcode will build and deploy it to the device. Note that sometimes when upgrading ionic or angular, it doesn't hurt to remove the ios folder and run ionic capacitor add ios
which will rebuild the xcode projects and related files using the latest bits from ionic.
Build Website.Client
To build the web version, cd into projects/Website.Client
and run ng build --base-href /pwa/
then copy the files from the www folder to the wwwroot folder on MCCESP.
Debugging
You can debug any of the clients by changing into the respective project directory and running ionic serve
to debug at localhost:8100 (the default if you launch from vscode). To debug on mobile, the easiest way is to launch the app on a device or even in the simulator on a mac and then connect to it from desktop Safari via Develop->Your Device->App Name - to set break points, you have to open up main.js and the app and library code will be browsable under there.
Running unit tests
TODO
Running end-to-end tests
TODO
Further help
Check out https://ionicframework.com and of course https://angular.io.