Technologies: SUMARiS App is an Angular App (Angular with Ionic).
This article will explain how to install your environment, then build the application.
-
Install NVM
-
Install Node v18 (e.g. v18.19.0)
nvm install 18.19.0
Check version in
package.json
-
Install global dependency:
npm install -g @ionic/cli@7.2.0 @angular/cli@18.2.8
Check versions in
package.json
-
Get sources (clone the repo) :
git clone ...
sudo apt-get install chromium-browser docker.io
-
Install project's dependencies:
cd sumaris-app npm install --force
-
Check environment configuration:
- Edit the file
src/environment/environment.ts
- Edit the file
-
Start the app
cd sumaris-app npm start
By default, the app should be accessible at http://localhost:4200
To change the default port, use this command instead:
cd sumaris-app ng serve --port [port]
The application should be accessible at localhost:4200
-
Check environment configuration:
- Edit the file
src/environment/environment-prod.ts
- Edit the file
-
Build:
npm run build:prod
-
Install the android build environment:
npm run android:install
-
Create a debug APK file:
npm run android:build npm run android:package
-
Check environment configuration:
- Edit the file
src/environment/environment-prod.ts
- Edit the file
-
Create a release APK file:
npm run android:build:prod npm run android:package:prod
- Install dependencies:
brew install cocoapods
- Build the app:
cd sumaris-app npm run ios:build
-
Open Xcode :
npm run ios:open
or
ionic cap open ios
- Ionic 4 colors: https://www.joshmorony.com/a-primer-on-css-4-variables-for-ionic-4/
- Migration to Ionic 4 tips: https://www.joshmorony.com/my-method-for-upgrading-from-ionic-3-to-ionic-4/
- Signing Android APK: See doc at https://www.c-sharpcorner.com/article/create-ionic-4-release-build-for-android/
- Checkout the project https://github.com/e-is/angular4-material-table
git clone https://github.com/e-is/angular4-material-table.git cd angular4-material-table
- Build the project:
npm install npm run build cp package*.json ./dist
- Link to your local NPM repo:
cd dist npm link
- Use it from Sumaris project:
cd <sumaris_app_root> npm link angular4-material-table