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
can i pass data from the middleware to controller ?!
like this node
function middleware(req, res, next){ req.user = {user:"incoming data"} next() } function controller(req, res){ console.log(req.user) // {user:"incoming data"} }
The text was updated successfully, but these errors were encountered:
This is what ctx.state is for. Ref: https://github.com/oakserver/oak#context
ctx.state
Sorry, something went wrong.
Since this has come up a few times, adding an FAQ: https://oakserver.github.io/oak/FAQ#how-do-i-pass-custom-propertiesstate-around
No branches or pull requests
can i pass data from the middleware to controller ?!
like this node
The text was updated successfully, but these errors were encountered: