Create a new suite application¶
Introduction¶
For this tutorial we are going to create a new app called EMA (Equipments Management Application).
In this part of the tutorial, you'll do the following:
- Create a new application.
- Configure different environments.
- Routing configuration.
- Configure the shell.
- Serve the application.
Create the app¶
- First of all remember to run this generator into the "/angular" folder.
-
Run the suite-app workspace generator:
yarn nx workspace-generator suite-app ema
.
The result of the generator should look like this:
Configure environments¶
By default a suite 3.0 application has 2 environments, one for development configured to work with docker and another one for production configured to be hosted by the BFF.
BFF urls are defined into the configuration files that are located in the
ema/assets/bootstrap
folder, this file is loaded when the
application starts to
get the rest of the configurations, locales and else.
Tip
If you need to set up more environments than the ones provided by default then follow the multi environment configuration guide.
Routing configuration¶
A suite application is just a SPA that works as an entry point to our suite modules, which are used as lego pieces to integrate new features. This means that our application projects do not include any logic or components.
For this tutorial we are going to add the equipments CRUD module to the app using the angular router.
Configure the shell¶
All the suite applications use the suite shell, this component has the look and feel that we want for all the applications. To configure it you can follow this guides:
- Navigation: Add sidebar buttons with this guide.
- Theming: Change the default dark theme from suite 3.0 with this guide.
Serve the application¶
Go to the workspace directory and launch the application to run against docker.
yarn start ema