0.0.0-20200224092041928 • Published 4 years ago
@zg2pro-org/calculateur-conges-api v0.0.0-20200224092041928
Generation of a NestJs project compatible with frontend frameworks (Vue, Angular, React and so on)
1-
$ npm install -g @nestjs/cli date-now-cli
$ nest new app-api
$ cd app-api
$ npm install --save-dev date-now-cli
2- Then go to the package.json and add the scripts:
$ "prepublish:version": "npm version 0.0.0-$(date-now --format='YYYYMMDDHHmmssSSS') --no-git-tag-version"
3- Also rename your project with your organization in prefix : name : "@my-org/app-api"
This will help you publish in npm registry
4- Then go to the tsconfig.json file and check the following properties:
"module": "commonjs",
"declaration": true,
"emitDecoratorMetadata": true,
"experimentalDecorators": true,
"target": "es2017",
"sourceMap": true,
5- In your code, when you inject a dependency, pay attention to inject in this fashion:
constructor(@Inject(HttpService) protected http) {
}
This will allow Angular to override the dependency during the injection as Angular uses a different DI engine (but compatible) and different set of core tools
0.0.0-20200224092041928
4 years ago
0.0.0-20200223120032572
4 years ago
0.0.0-20200220165316195
4 years ago
0.0.0-20200220134952508
4 years ago
0.0.0-20200220154828910
4 years ago
0.0.0-20200220162017620
4 years ago
0.0.0-20200220132532598
4 years ago
0.0.0-20200220123537186
4 years ago
0.0.0-20200220104158834
4 years ago
0.0.0-20200219084546989
4 years ago
0.0.0-20200218122935477
4 years ago
0.0.0-1
4 years ago