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
Nuxt3: nitro.publicAssets does not copy custom dirs to .output/public #25185
Comments
Stackblitz does produce a |
Would you be able to provide a reproduction? 🙏 More infoWhy 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 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 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: |
@pstatham-exp As you can see it is semi-working. It gives public access to serve content under dir path ignoring baseURL in nitro.publicAssets reproduction steps to reproduce:
it works until I change the img src in index.vue to use publicAssets.baseURL instead of publicAssets.dir path |
We need to provide a resolver to let Vite know that the custom baseURL you provide matches that directory on disk. (We already do something very similar for layer public dirs.) |
Environment
Nuxt project info: 11:47:55 PM
Reproduction
The StackBlitz and CodeSandbox do not allow
.output/
directories, so cannot reproduce thereDescribe the bug
Following the description of #18918 I am unable to add additional directories to the
.output/public
folder:This assumes I have a directory called
samples
at the same level of thenuxt.config.ts
.When running
npm run build
, the.output/public
does not contain this directory.Additional context
No response
Logs
No response
The text was updated successfully, but these errors were encountered: