New issue
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
Escape or replace square brackets in file names? #16
Comments
@thalesagapito Hey, did you find this error when using |
I was using vite-ssr, I just mentioned the nuxt issue because the nuxt team has faced the same problem before. Sorry if I wasn't clear. |
@thalesagapito from v0.4.9 I set replaceSquareBrackets to false by default because it will break dynamic pages, you can manually set it to true it you want. |
From v0.5.0 replace square brackets should also works in dynamic pages with replaceSquareBrackets option set to true. |
Like with the nuxt routing module, the generation of routes with square brackets makes the plugin unusable in aws API Gateway environments. Original issue for reference: nuxt/nuxt#7625.
The problem is that API Gateway does not consider urls with square brackets valid, which makes dynamic and catch-all route files throw errors when loaded. Is there any way to replace these on build?
For now, I believe a workaround is to remove the brackets manually inside the dist folder, but ideally the plugin could have a way ty prevent this problem.
The text was updated successfully, but these errors were encountered: