z4nr34l / next-easy-middlewares

Missing polyfill for multiple next.js middlewares
https://next-easy-middlewares.vercel.app/
MIT License
84 stars 4 forks source link

Support multiple global middlewares #52

Open Zenoo opened 1 week ago

Zenoo commented 1 week ago

Is your feature request related to a problem? Please describe. I have 2 middlewares that need to run for every route: one for NextAuth and one for I18n.

Describe the solution you'd like

const globalMiddlewares = {
  before: [auth, i18n],
  after: null,
};

Describe alternatives you've considered I'm not sure how to do that otherwise, I'm open to suggestions if it's possible another way.

linear[bot] commented 1 week ago

NEM-20 Support multiple global middlewares

z4nr34l commented 2 days ago

Good catch! Will add this soon! :D