generator-terasoluna v1.0.0
generator-terasoluna 
A yeoman generator to add primeNG ,tsc-core-log, swagger and the possibility of deploying your project in Altemista.
Installation
First, install Yeoman and generator-terasoluna using npm (we assume you have pre-installed node.js).
npm install -g yo
npm install -g generator-terasoluna
Then run this command to add primeng and log lib into your project:
yo terasoluna
Altemista
The generator will ask the following questions in case you want to add in the future your project in Altemista
- Could you type the project name of Altemista?: The project name from your Altemista console.
- Could you type the image name for the frontend part?: Image name of your angular project that you want to use to push the image to Altemista. The name needs to be the same than your angular project
- Could you type the context path of your backend project?: The context path of your backend project to link with the angular project.
The following files will be copied in your root angular project:
- buildimageFrontend.bat
- Dockerfile
- app.nginx.conf
And finally this file will be added in altemista folder
- deploymentFrontend.yaml
We will explain later how to use these files.
Usage
PrimeNG
Once the proccess has finished, you can add all the features from primeNG. Example
Go to src\app\app.module.ts and add this
import {ButtonModule} from 'primeng/button'; imports: [ ..... ButtonModule, ............. ],
Go to src\app\app.component.html and add this
<p-button icon="pi pi-check" label="Click"></p-button>
Start your serve and now you will be able to see the modifications.
Tsc-core-log
See more in the tsc-core-log
Swagger
Once the proccess has finished, you can generate model interfaces and web service clients from a Swagger 2.0 specification. The generated classes follow the principles of Angular.
Paste the swagger.json file in your path of your root angular project.
In your project, run:
cd <your_angular_app_dir>
<your_angular_app_dir>\node_modules\.bin\ng-swagger-gen -i <path_to_swagger_json> [-o output_dir]
Deploy in Altemista
See more in Angular in Altemista