Skip to content

Commit

Permalink
Merge pull request #1 from gossi/patch-1
Browse files Browse the repository at this point in the history
Add import statement
  • Loading branch information
simonihmig authored Sep 29, 2020
2 parents 8c35231 + 003d053 commit f0cb285
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@ Tracked Redux
This library provides an autotracked version of [Redux](https://redux.js.org/).

```js
import { createStore } from 'tracked-redux';

const store = createStore((state = { todos: [] }, action) => {
if (action.type === 'ADD_TODO') {
return { todos: [...state.todos, action.todo] };
Expand Down

0 comments on commit f0cb285

Please sign in to comment.