Created
August 9, 2016 13:15
-
-
Save ThomasCrevoisier/59b74a8a0d0e4736637447574e809a2a to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
app.model({ | |
state: { title: 'hep' }, | |
reducers: { | |
update: (data, state) => { | |
console.log(data); | |
return { title: 'hey' }; | |
} | |
}, | |
effects: { | |
add: (data, state, send, done) => { | |
console.log('plop-effect'); | |
send('update', {title: 'lpop'}); | |
} | |
} | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment