We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
nuxt-csurf
1 parent 18b0ab0 commit 63210ecCopy full SHA for 63210ec
src/features.ts
@@ -50,6 +50,12 @@ export function setupBase(nuxt: Nuxt, hub: HubConfig) {
50
if (nuxt.options.dev) {
51
addDevToolsCustomTabs(nuxt, hub)
52
}
53
+
54
+ // Add routeRules to work with some security modules
55
+ nuxt.options.routeRules = nuxt.options.routeRules || {}
56
+ nuxt.options.routeRules['/api/_hub/**'] = nuxt.options.routeRules['/api/_hub/**'] || {}
57
+ // @ts-expect-error csurf is not typed here
58
+ nuxt.options.routeRules['/api/_hub/**'].csurf = false
59
60
61
export async function setupAI(nuxt: Nuxt, hub: HubConfig) {
0 commit comments