Last active
August 6, 2024 11:37
-
-
Save z4nr34l/c02bdc44493e26b8f0c807ff8dfd8ee8 to your computer and use it in GitHub Desktop.
next-easy-middlewares multipath middleware chain
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { createMiddleware } from '@rescale/nemo'; | |
import { internalMiddleware } from '@/app/(platform)/(personal)/_middleware'; | |
const middlewares = { | |
'/(home|settings){/:path}?': internalMiddleware, | |
}; | |
export const middleware = createMiddleware( | |
middlewares as never, | |
); | |
export const config = { | |
matcher: ['/(home|settings)(.*)'], | |
}; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment