goatslacker / alt

Isomorphic flux implementation
http://alt.js.org/
3.45k stars 322 forks source link

StoreModel#waitFor doesn't work #685

Open dangnm opened 7 years ago

dangnm commented 7 years ago

I have the following CoffeeScript code snippet ` class AStore @displayName: 'AStore'

onTest: (props) -> @waitFor(Myapp.BStore.dispatchToken) console.log("AStore action test") ... class BStore @displayName: 'BStore'

onTest: (props) -> console.log("BStore action test") ... class AActions ... class BActions ... ` When I try to call AActions.test() , it just prints the message "AStore action test" without waiting BStore actions called. How can I force AActions.test() to wait for BActions.test() is excuted completely?