ng2redux simple application
April 25, 2016 ยท View on GitHub
Overview
ng2redux is Angular2 bindings for Redux. This repository includes a very simple example of usage of ng2redux. It implements counter application with two different pages. Each page shows different approach of working with Redux store.
-
Usage of
@Connectdecorator, that allows to bind properties and actions to a component. It maps state to properties and updates them on every state change. It also mapsstore's dispatch method to actions and allows to dispatch actions oncomponent's events. -
Injection of
Storeinto acomponent. Since the store is injected, it is available incomponent's scope and allows a user to subscribe tostatechanges and to dispatch actions.
Live example
Live example can be found here: http://forforeach.github.io/ng2redux-simple-starter
Quickstart
Clone this repository and run:
npm run setupnpm start
Dependencies
Troubleshooting
If you find yourself running into issues during installation or running of this application, please open an issue.
Based on
This app is based on Google's Web Starter Kit. This is great starter for web apps that implements build workflow with Gulp.
License
MIT Copyright 2016 Dima Kuzmich