nuxt / nuxt/bridge

`vite: { legacy: false }`: After running `run build`, assets resources cannot be accessed.

Open
#1,332 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

pending triage
Dominant language
TypeScript
Stars
285
Forks
33
Avg merge
22h 38m
Merged PRs (30d)
3

Description

Environment

  • Operating System: Darwin
  • Node Version: v22.9.0
  • Nuxt Version: 2.18.1
  • CLI Version: 3.14.0
  • Nitro Version: 2.9.7
  • Package Manager: npm@10.8.3
  • Builder: webpack
  • User Config: -
  • Runtime Modules: -
  • Build Modules: -

Why? i using vite

Reproduction

https://stackblitz.com/~/github.com/medz/github-ocrw7j

Describe the bug

After enabling vite and running nuxi build, the static images will be renamed to xxx-xxx.png and referenced to xxx.xxx.png in the vue template.

Additional context
npm run build
npm run start
Logs

No response

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the linked StackBlitz reproduction and run npm run build followed by npm run start. Compare the generated static image names with the references in the Vue templates; the issue is done when built assets are accessible and their generated names match the references.

Written by the indexing model from the issue text.

Assessment

Tech stack
nuxt, typescript, vite, webpack
Domain
build-system, frontend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.