mirror of
https://github.com/Alfresco/alfresco-content-app.git
synced 2025-07-24 17:31:52 +00:00
[ACS-4534] nx workspace support for aca (#3143)
* ACS-4534 Added nx workspace support * ACS-4534 Updated package-lock.json file * ACS-4534 Configured cache directory and affected command * ACS-4534 Updated README * ACS-4534 Updated more README files * ACS-4534 Fixed lint * ACS-4534 Address comment for readme * ACS-4534 Removed redundant build-libs script * ACS-4534 Fixed start script * ACS-4534 Updated some left documentation * ACS-4534 Added more helper scripts, addressed PR comments * ACS-4534 Updated package-lock.json after rebasing * ACS-4534 Fix stylelint issue
This commit is contained in:
@@ -4,22 +4,22 @@ This library was generated with [Angular CLI](https://github.com/angular/angular
|
||||
|
||||
## Code scaffolding
|
||||
|
||||
Run `ng generate component component-name --project aca-shared` to generate a new component. You can also use `ng generate directive|pipe|service|class|guard|interface|enum|module --project aca-shared`.
|
||||
Run `nx generate component component-name --project aca-shared` to generate a new component. You can also use `nx generate directive|pipe|service|class|guard|interface|enum|module --project aca-shared`.
|
||||
|
||||
> Note: Don't forget to add `--project aca-shared` or else it will be added to the default project in your `angular.json` file.
|
||||
|
||||
## Build
|
||||
|
||||
Run `ng build aca-shared` to build the project. The build artifacts will be stored in the `dist/` directory.
|
||||
Run `nx build aca-shared` to build the project. The build artifacts will be stored in the `dist/` directory.
|
||||
|
||||
## Publishing
|
||||
|
||||
After building your library with `ng build aca-shared`, go to the dist folder `cd dist/aca-shared` and run `npm publish`.
|
||||
After building your library with `nx build aca-shared`, go to the dist folder `cd dist/aca-shared` and run `npm publish`.
|
||||
|
||||
## Running unit tests
|
||||
|
||||
Run `ng test aca-shared` to execute the unit tests via [Karma](https://karma-runner.github.io).
|
||||
Run `nx test aca-shared` to execute the unit tests via [Karma](https://karma-runner.github.io).
|
||||
|
||||
## Further help
|
||||
|
||||
To get more help on the Angular CLI use `ng help` or go check out the [Angular CLI README](https://github.com/angular/angular-cli/blob/master/README.md).
|
||||
To get more help on the NX use `nx help` or go check out the [NX documentation](https://nx.dev/getting-started/intro) page.
|
||||
|
54
projects/aca-shared/project.json
Normal file
54
projects/aca-shared/project.json
Normal file
@@ -0,0 +1,54 @@
|
||||
{
|
||||
"$schema": "../../node_modules/nx/schemas/project-schema.json",
|
||||
"name": "aca-shared",
|
||||
"sourceRoot": "projects/aca-shared/src",
|
||||
"projectType": "library",
|
||||
"prefix": "lib",
|
||||
"targets": {
|
||||
"build": {
|
||||
"executor": "@angular-devkit/build-angular:ng-packagr",
|
||||
"options": {
|
||||
"tsConfig": "projects/aca-shared/tsconfig.lib.json",
|
||||
"project": "projects/aca-shared/ng-package.json"
|
||||
},
|
||||
"configurations": {
|
||||
"production": {
|
||||
"tsConfig": "projects/aca-shared/tsconfig.lib.prod.json"
|
||||
}
|
||||
},
|
||||
"defaultConfiguration": "production",
|
||||
"outputs": [
|
||||
"{workspaceRoot}/dist/@alfresco/aca-shared"
|
||||
]
|
||||
},
|
||||
"test": {
|
||||
"executor": "@angular-devkit/build-angular:karma",
|
||||
"options": {
|
||||
"codeCoverage": true,
|
||||
"main": "projects/aca-shared/test.ts",
|
||||
"tsConfig": "projects/aca-shared/tsconfig.spec.json",
|
||||
"karmaConfig": "projects/aca-shared/karma.conf.js"
|
||||
},
|
||||
"configurations": {
|
||||
"adfprod": {
|
||||
"tsConfig": "projects/aca-shared/tsconfig.spec.adf.json"
|
||||
}
|
||||
}
|
||||
},
|
||||
"lint": {
|
||||
"executor": "@angular-eslint/builder:lint",
|
||||
"options": {
|
||||
"lintFilePatterns": [
|
||||
"projects/aca-shared/**/*.ts",
|
||||
"projects/aca-shared/**/*.html"
|
||||
],
|
||||
"cache": true,
|
||||
"cacheLocation": ".eslintcache",
|
||||
"ignorePath": ".eslintignore"
|
||||
},
|
||||
"outputs": [
|
||||
"{options.outputFile}"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user