mirror of
https://github.com/zoriya/flood.git
synced 2026-06-01 18:47:44 +00:00
Move from Redux to vanilla Flux
This commit is contained in:
@@ -1,5 +1,15 @@
|
||||
import {Dispatcher} from 'flux';
|
||||
|
||||
let AppDispatcher = new Dispatcher();
|
||||
class FloodDispatcher extends Dispatcher {
|
||||
dispatchUIAction(action) {
|
||||
this.dispatch({source: 'UI_ACTION', action});
|
||||
}
|
||||
|
||||
dispatchServerAction(action) {
|
||||
this.dispatch({source: 'SERVER_ACTION', action});
|
||||
}
|
||||
}
|
||||
|
||||
let AppDispatcher = new FloodDispatcher();
|
||||
|
||||
export default AppDispatcher;
|
||||
|
||||
Reference in New Issue
Block a user