10000
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
import Immutable from 'immutable'; export class NewsComment { static create() { return Immutable.fromJS({ id: '', content: '', vote: [] }); } } export class News { static create() { return Immutable.fromJS({ id: '', content: '', comments: [] }); } }
2、定义Action
import { createAction } from 'redux-actions'; import { ACT_NEWS_SELECT } from './constants'; export const actNewsSelect = createAction(ACT_NEWS_SELECT);
3、使用Action
onSelectNews(id){ //触发action console.log('onSelectNews') this.props.actNewsSelect(id) Actions['articledetail']() } function bindAction(dispatch) { return { actNewsSelect: (id) => dispatch(actNewsSelect(id)) } }
The text was updated successfully, but these errors were encountered:
No branches or pull requests
2、定义Action
3、使用Action
The text was updated successfully, but these errors were encountered: