-
-
Notifications
You must be signed in to change notification settings - Fork 7.4k
Closed
Labels
Description
Describe the bug
As title
Reproduction
https://github.com/JounQin/test/tree/vite_define
System Info
System:
OS: macOS 12.0
CPU: (16) x64 Intel(R) Core(TM) i9-9880H CPU @ 2.30GHz
Memory: 17.84 GB / 64.00 GB
Shell: 5.8 - /bin/zsh
Binaries:
Node: 12.22.5 - ~/.nvm/versions/node/v12.22.5/bin/node
Yarn: 1.22.11 - /usr/local/bin/yarn
npm: 6.14.14 - ~/.nvm/versions/node/v12.22.5/bin/npm
Browsers:
Chrome: 92.0.4515.159
Firefox: 91.0.2
Safari: 15.0
npmPackages:
vite: ^1.0.0-rc.13 => 1.0.0-rc.13Used Package Manager
yarn
Logs
vite:config env mode: production +0ms
vite:config env: {} +1ms
vite:config config resolved in 94ms +1ms
Building production bundle...
vite:build:resolve /src/main.js --> /Users/JounQin/Workspaces/Local/test/src/main.js +0ms
[vite] Build errored out.
Error: Could not resolve './"globalThis".css' from src/main.js
at error (/Users/JounQin/Workspaces/Local/test/node_modules/rollup/dist/shared/rollup.js:151:30)
at ModuleLoader.handleResolveId (/Users/JounQin/Workspaces/Local/test/node_modules/rollup/dist/shared/rollup.js:19862:24)
at /Users/JounQin/Workspaces/Local/test/node_modules/rollup/dist/shared/rollup.js:19856:26 {
code: 'UNRESOLVED_IMPORT',
watchFiles: [
'/Users/JounQin/Workspaces/Local/test/index.html',
'/Users/JounQin/Workspaces/Local/test/src/main.js',
'/Users/JounQin/Workspaces/Local/test/node_modules/@vue/runtime-dom/dist/runtime-dom.esm-bundler.js',
'/Users/JounQin/Workspaces/Local/test/node_modules/@vue/runtime-core/dist/runtime-core.esm-bundler.js',
'/Users/JounQin/Workspaces/Local/test/node_modules/@vue/shared/dist/shared.esm-bundler.js',
'/Users/JounQin/Workspaces/Local/test/node_modules/@vue/reactivity/dist/reactivity.esm-bundler.js',
'/Users/JounQin/Workspaces/Local/test/src/App.vue',
'/Users/JounQin/Workspaces/Local/test/src/App.vue?vue&type=script&lang.js',
'/Users/JounQin/Workspaces/Local/test/src/App.vue?vue&type=template&id=601a3950&lang.js'
]
}Validations
- Follow our Code of Conduct
- Read the Contributing Guidelines.
- Read the docs.
- Check that there isn't already an issue that reports the same bug to avoid creating a duplicate.
- Make sure this is a Vite issue and not a framework-specific issue. For example, if it's a Vue SFC related bug, it should likely be reported to https://github.com/vuejs/vue-next instead.
- Check that this is a concrete bug. For Q&A open a GitHub Discussion or join our Discord Chat Server.
- The provided reproduction is a minimal reproducible example of the bug.