8000 readAsset build error · Issue #3374 · nitrojs/nitro · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

readAsset build error #3374

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

Open
zhyc9de opened this issue May 28, 2025 · 1 comment
Open

readAsset build error #3374

zhyc9de opened this issue May 28, 2025 · 1 comment

Comments

@zhyc9de
Copy link
zhyc9de commented May 28, 2025

https://github.com/nitrojs/nitro/blob/8c2a2d8589a1c65b091f8bce1ca25d756f25bb11/src/build/plugins/public-assets.ts#L78C1-L79C1

This is the code that I actually compiled

function readAsset (id) {
  const serverDir = dirname(fileURLToPath(import.meta.url));
  return promises.readFile(resolve$1(serverDir, assets[id].path))
}

the global variable was not referenced, so the _nuxt file could not be found

Image

my env
node v22.15.1

@kricsleo
Copy link
Member

Please provide a minimal reproduction (e.g., Stackblitz or a Github repo) so we can debug 🙏

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

3 participants
0