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
const bar = [1, 2, 3]; foo(...bar);
等同于:
foo.apply(this, bar);
一个用例:
const middleware = [ thunk, api, !__NODE__ && createLogger(), ].filter(Boolean); export default function configureStore(initialState) { const store = createStore( rootReducer, initialState, compose( applyMiddleware(...middleware), ) ); return store; }
redux 的 applyMiddleware 方法不能接受数组,可以利用这个方法方便地根据环境改变参数。
The text was updated successfully, but these errors were encountered:
No branches or pull requests
等同于:
一个用例:
redux 的 applyMiddleware 方法不能接受数组,可以利用这个方法方便地根据环境改变参数。
The text was updated successfully, but these errors were encountered: