https://github.com/gmarcos87/generator-firedux
ngRx/store generator for Ionic2 projects
https://github.com/gmarcos87/generator-firedux
angular2 angularjs ionic2 ngrx yeoman
Last synced: about 1 month ago
JSON representation
ngRx/store generator for Ionic2 projects
- Host: GitHub
- URL: https://github.com/gmarcos87/generator-firedux
- Owner: gmarcos87
- License: mit
- Created: 2016-11-30T18:26:41.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2017-02-16T03:27:32.000Z (about 8 years ago)
- Last Synced: 2025-02-17T10:16:51.469Z (2 months ago)
- Topics: angular2, angularjs, ionic2, ngrx, yeoman
- Language: TypeScript
- Size: 10.7 KB
- Stars: 8
- Watchers: 4
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# generator-firedux [![NPM version][npm-image]][npm-url] [![Build Status][travis-image]][travis-url] [![Dependency Status][daviddm-image]][daviddm-url] [](https://coveralls.io/github/gmarcos87/generator-firedux?branch=master)
> ngRx/store generator for Ionic2 proyects## Installation
First, install [Yeoman](http://yeoman.io) and generator-firedux using [npm](https://www.npmjs.com/) (we assume you have pre-installed [node.js](https://nodejs.org/)).
```bash
npm install -g yo
npm install -g generator-firedux
```Then in your ./ionic-app/src generate your new store (ngrx/store + AngularFire + Ionic2):
```bash
yo firedux newstore
```Import your new store in app.module.ts
```javascript
import { NewstoreActions } from '../actions/newstore.actions'
import { NewstoreEffects } from '../effects/newstore.effects'
import { NewstoreReducer } from '../reducers/newstore.reducer'
import { NewstoreService } from '../providers/newstore.service'...
imports: [
...//others effects or imports
EffectsModule.runAfterBootstrap(NewstoreEffects)
StoreModule.provideStore({ newstore: NewstoreReducer, otherstore: OtherstoreReducer })
]
...
providers :[
...//others providers or services
NewstoreService,
NewstoreActions
]
```Add Newstore to services/app-state.ts
```javascript
...
import { NewstoreI } from '../models/newstore.model';
...
export interface AppState {
...//others stores
newstore: NewstoreI[]
}
```## Getting To Know Yeoman
* Yeoman has a heart of gold.
* Yeoman is a person with feelings and opinions, but is very easy to work with.
* Yeoman can be too opinionated at times but is easily convinced not to be.
* Feel free to [learn more about Yeoman](http://yeoman.io/).## License
MIT © [Marcos Gutierrez](http://pixxel.com.ar)
[npm-image]: https://badge.fury.io/js/generator-firedux.svg
[npm-url]: https://npmjs.org/package/generator-firedux
[travis-image]: https://travis-ci.org/gmarcos87/generator-firedux.svg?branch=master
[travis-url]: https://travis-ci.org/gmarcos87/generator-firedux
[daviddm-image]: https://david-dm.org/gmarcos87/generator-firedux.svg?theme=shields.io
[daviddm-url]: https://david-dm.org/gmarcos87/generator-firedux
[coveralls-image]: https://coveralls.io/repos/gmarcos87/generator-firedux/badge.svg
[coveralls-url]: https://coveralls.io/r/gmarcos87/generator-firedux