Skip to content
Snippets Groups Projects
Commit 878a899b authored by Florent Poittevin's avatar Florent Poittevin
Browse files

chore: update README.adoc to use pnpm

parent 285aed18
No related branches found
No related tags found
No related merge requests found
......@@ -6,10 +6,10 @@ Solidify-Frontend is the angular frontend part of _Solidify_ framework, develope
== Prerequisites
* Install https://nodejs.org/en/:[NodeJS LTS] : Use ALWAYS the node "LTS" version.
Version currently supported is Node 16.
* Run `npm install -g angular/cli@13.2.1` to install angular cli globally
* Run `npm install -g typescript@4.5.5` to install typescript globally
* Have pnpm installed (use version mentioned in 'packageManager' field in package.json).
pnpm will automatically download node needed for the project.
* Install https://angular.io/cli[Angular CLI] with command `pnpm install -g angular/cli@X.Y.Z (use version mentioned in '@angular/core' field in package.json)
* Install https://www.typescriptlang.org/[typescript] with command `pnpm install -g typescript@X.Y.Z` (use version mentioned in 'typescript' field in package.json)
* You should access to https://nexus.unige.ch/, if not please follow instructions in <<install_outside_unige>>
== Install
......@@ -17,7 +17,7 @@ Version currently supported is Node 16.
=== Install inside UNIGE Network
----
npm install
pnpm install
----
=== Install outside UNIGE Network [[install_outside_unige]]
......@@ -46,7 +46,7 @@ After that, you need to delete `package-lock.json` on `solidify-frontend`
Then you will be able to run the following command
----
npm install
pnpm install
----
== Build
......@@ -57,7 +57,7 @@ If you want to be able to build schematics from this lib, you need to run :
----
cd projects/solidify-frontend
npm run build
pnpm run build
----
== SSR
......@@ -166,7 +166,7 @@ To enable SSR in a deployment env, set env variable 'SSR_ENABLED' to 'enabled'.
On your project that use SSR feature, the following build command will build 'browser' and 'server' build
----
npm run build
pnpm run build
----
The build artifacts for 'browser' will be stored in the `dist/my-app-portal/browser` directory.
......@@ -175,7 +175,7 @@ The build artifacts for 'server' will be stored in the `dist/my-app-portal/serve
=== Dev with SSR
If you want to test the SSR locally, you will need to build the project to serve it later.
Note that to simplify the debugging work, you can build by omitting the optimisation passes using the command `npm run build:dev`
Note that to simplify the debugging work, you can build by omitting the optimisation passes using the command `pnpm run build:dev`
This command allow also to play with the configuration easily at runtime (no need to rebuild each time you want to change the config).
For that you should use the following files:
......@@ -201,10 +201,10 @@ If you want to integrate the lib on you project you need to copy the folder call
It's recommended to add the following script on the package.json of project that use _Solidify Frontend_ :
----
"build-solidify": "rm -rf ./node_modules/solidify-frontend && cd ../solidify-frontend && npm run build && cp -fr dist/solidify-frontend ../my-project-portal/node_modules && cd ../my-project-portal",
"build-solidify": "rm -rf ./node_modules/solidify-frontend && cd ../solidify-frontend && pnpm run build && cp -fr dist/solidify-frontend ../my-project-portal/node_modules && cd ../my-project-portal",
----
You can use the command `npm run build-solidify` from your project that use _Solidify-Frontend_.
You can use the command `pnpm run build-solidify` from your project that use _Solidify-Frontend_.
NB : The folder of the project that use _Solidify-Frontend_ ( ex : `my-project-portal`) should be sibling of the current folder !
......@@ -230,7 +230,7 @@ To test locally, install `@angular-devkit/schematics-cli` globally and use the `
That tool acts the same as the `generate` command of the Angular CLI, but also has a debug mode.
----
npm i -g @angular-devkit/schematics-cli
pnpm i -g @angular-devkit/schematics-cli
----
Check the documentation with
......@@ -241,7 +241,7 @@ schematics --help
=== Unit Testing
`npm run test-schematics` will run the unit tests, using Jasmine as a runner and test framework.
`pnpm run test-schematics` will run the unit tests, using Jasmine as a runner and test framework.
=== Usage
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment