Skip to content
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

cors headers appear as fixed values. #27368

Closed
angrymusic opened this issue May 27, 2024 · 1 comment
Closed

cors headers appear as fixed values. #27368

angrymusic opened this issue May 27, 2024 · 1 comment

Comments

@angrymusic
Copy link

angrymusic commented May 27, 2024

Environment

Nuxt project info: 4:35:54 PM


  • Operating System: Linux
  • Node Version: v18.17.0
  • Nuxt Version: 3.10.3
  • CLI Version: 3.10.1
  • Nitro Version: 2.9.3
  • Package Manager: npm@9.6.6
  • Builder: -
  • User Config: devtools, typescript, vue, modules, i18n, quasar, site, nitro, routeRules, sitemap, runtimeConfig, vite
  • Runtime Modules: @nuxtjs/i18n@8.1.1, @pinia/nuxt@0.5.1, @pinia-plugin-persistedstate/nuxt@1.2.0, @nuxtjs/seo@2.0.0-rc.9, nuxt-quasar-ui@2.1.0
  • Build Modules: -

👉 Report an issue: https://github.com/nuxt/nuxt/issues/new 4:35:54 PM

👉 Suggest an improvement: https://github.com/nuxt/nuxt/discussions/new

👉 Read documentation: https://nuxt.com

Reproduction

.

Describe the bug

my nuxt.config.ts
nitro: {
routeRules: {
"/": {
cors: false,
},
"/api/": {
proxy: "http://localhost:8080/api/
",
},
"/uploads/": {
proxy: "http://localhost:8080/uploads/
",
},
"/self-api/": {
proxy: "http://localhost:3000/api/
",
},
},
},

// exclude all URLs that start with /admin
routeRules: {
"/": {
cors: false,
},
"/admin/": {
robots: false,
},
},
sitemap: {
exclude: ["/admin/
"],
sources: ["/solutionUrls"],
},

i didn;'t set cors..
i want to disable cors header

Additional context

Logs

No response

Copy link
Contributor

Would you be able to provide a reproduction? 🙏

More info

Why do I need to provide a reproduction?

Reproductions make it possible for us to triage and fix issues quickly with a relatively small team. It helps us discover the source of the problem, and also can reveal assumptions you or we might be making.

What will happen?

If you've provided a reproduction, we'll remove the label and try to reproduce the issue. If we can, we'll mark it as a bug and prioritize it based on its severity and how many people we think it might affect.

If needs reproduction labeled issues don't receive any substantial activity (e.g., new comments featuring a reproduction link), we'll close them. That's not because we don't care! At any point, feel free to comment with a reproduction and we'll reopen it.

How can I create a reproduction?

We have a couple of templates for starting with a minimal reproduction:

👉 https://stackblitz.com/github/nuxt/starter/tree/v3-stackblitz
👉 https://codesandbox.io/s/github/nuxt/starter/v3-codesandbox

A public GitHub repository is also perfect. 👌

Please ensure that the reproduction is as minimal as possible. See more details in our guide.

You might also find these other articles interesting and/or helpful:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants