https://github.com/loiane/angular-ngrx-example
Sample Angular NgRx application with Lazy Loading and ngrx code as modules
https://github.com/loiane/angular-ngrx-example
Last synced: 7 months ago
JSON representation
Sample Angular NgRx application with Lazy Loading and ngrx code as modules
- Host: GitHub
- URL: https://github.com/loiane/angular-ngrx-example
- Owner: loiane
- Created: 2017-07-19T20:33:58.000Z (about 8 years ago)
- Default Branch: main
- Last Pushed: 2023-01-06T01:32:23.000Z (over 2 years ago)
- Last Synced: 2025-02-27T11:50:05.003Z (7 months ago)
- Language: TypeScript
- Homepage:
- Size: 2.52 MB
- Stars: 134
- Watchers: 12
- Forks: 62
- Open Issues: 25
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# AngularNgrxExample
This project was generated with [Angular CLI](https://github.com/angular/angular-cli) version 10.1.4.
Demo: https://salmon-sky-0f83f980f.azurestaticapps.net/products
## Development server
Run `ng serve` for a dev server. Navigate to `http://localhost:4200/`. The app will automatically reload if you change any of the source files.
## Code scaffolding
Run `ng generate component component-name` to generate a new component. You can also use `ng generate directive|pipe|service|class|guard|interface|enum|module`.
## Build
Run `ng build` to build the project. The build artifacts will be stored in the `dist/` directory. Use the `--prod` flag for a production build.
## Running unit tests
Run `ng test` to execute the unit tests via [Karma](https://karma-runner.github.io).
## Running end-to-end tests
Run `ng e2e` to execute the end-to-end tests via [Protractor](http://www.protractortest.org/).
## 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).
## NgRx commands
```
ng add @ngrx/schematics@latest
ng add @ngrx/store@latest
ng add @ngrx/store-devtools@latest
ng add @ngrx/effects@latest
ng add @ngrx/entity@latest
ng add @ngrx/data@latestng generate @ngrx/schematics:store Product --statePath store --module products.module.ts
ng generate @ngrx/schematics:entity Product --flat false --module products.module.ts
ng generate @ngrx/schematics:effect store/Product --module products.module.ts --api true
ng generate @ngrx/schematics:container Products --state store/product.reducer.ts --stateInterface ProductState
ng generate @ngrx/schematics:selector store/Productsng generate @ngrx/schematics:action Header
ng generate @ngrx/schematics:reducer Header --module ../header.module.ts
ng generate @ngrx/schematics:selector store/headerng generate @ngrx/schematics:reducer App --module ../app.module.ts
```