
Security News
Attackers Are Hunting High-Impact Node.js Maintainers in a Coordinated Social Engineering Campaign
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.
async-dispatch
Advanced tools
[](https://www.npmjs.com/package/async-dispatch)
async-dispatch is a middleware can be added with no time to privilage the asynchronous server requests into your Redux store
For more informatiom about the future of redux-logger, check out the discussion here.
npm i --save async-dispatch
import asyncDispatchMiddleware from "async-dispatch";
import { createStore } from "redux";
import { applyMiddleware } from "redux";
const store = createStore(
rootReducer,
applyMiddleware(asyncDispatchMiddleware)
);
// Note passing middleware as the third argument requires redux@>=3.1.0
Then applying this middleware is simple as
const LoginReducer = (state = intialState, action) => {
//actionTypes.LOGIN
login(userData).then((data) => {
if (data.error) {
action.asyncDispatch({
type: actionTypes.ERROR,
message: data.error,
});
} else {
action.asyncDispatch({
type: actionTypes.SUCCESS,
user: data,
message: "Logged successfully",
});
}
});
return { ...state };
})
Meanwhile you are leveraging your store as usual as you used to do
const mapDispatchToProps = (dispatch) => {
return {
submit: () => dispatch({ type: actionTypes.LOGIN })
}
}
//Inside your component
SubmitHandler = () => {
return props.submit();
}
MIT
FAQs
[](https://www.npmjs.com/package/async-dispatch)
We found that async-dispatch demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.

Security News
Axios compromise traced to social engineering, showing how attacks on maintainers can bypass controls and expose the broader software supply chain.

Security News
Node.js has paused its bug bounty program after funding ended, removing payouts for vulnerability reports but keeping its security process unchanged.