vue style not found
See original GitHub issueDescribe the bug
vite build Production environment package style file missing
Reproduction
https://github.com/leafront/my-vue-app
System Info
Output of npx envinfo --system --npmPackages vite,@vitejs/plugin-vue --binaries --browsers
:
System:
OS: windows 10
CPU: (12) x64 Intel(R) Core(TM) i7-10700 CPU @ 2.90GHz
Memory: 12 GB / 32.00 GB
Shell: 5.8 - /bin/zsh
Binaries:
Node: 14.16.1 - D:\Program Files\nodejs\
npm: 6.14.12 - ~D:\Program Files\nodejs\npm
Browsers:
Chrome: 89.0.4389.114
Used package manager:
Logs
╰─➤ sudo npm run build 1 ↵
Password:
> my-vue-app@0.0.0 build /Users/leaf/my-vue-app
> vite build
vite v2.2.1 building for production...
✓ 17 modules transformed.
dist/index.html 0.71kb
dist/assets/Footer.9ea5d8f6.js 0.14kb / brotli: 0.11kb
dist/assets/HelloWorld.5224c65b.js 0.28kb / brotli: 0.18kb
dist/assets/HelloWorld.7ca16950.css 0.02kb / brotli: 0.02kb
dist/assets/Test.cda07b1d.js 0.27kb / brotli: 0.17kb
dist/assets/Footer.9751d05f.css 0.04kb / brotli: 0.03kb
dist/assets/index.974cc591.js 1.85kb / brotli: 0.82kb
dist/assets/vendor.7f384ad1.js 64.02kb / brotli: 22.47kb
Before submitting the issue, please make sure you do the following
- 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.
- Provide a description in this issue that describes the bug.
- 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.
Issue Analytics
- State:
- Created 2 years ago
- Comments:11 (3 by maintainers)
Top Results From Across the Web
why my css code is not working in vuejs? - Stack Overflow
When you use scoped on style tags in .vue files it adds an attribute specifier to each of your CSS selectors. When Vue...
Read more >I don't know why style tag not working - Get Help - Vue Forum
Hello, I'm relatively new to Vue and now trying to make a simple SPA webpage. And I ran into this problem and can't...
Read more >Styling Vue components with CSS - Learn web development
While this tutorial will not be using such tools, it's good to know that when including such code in the assets folder it...
Read more >Styling Vue Single-File Components - This Dot Labs
By using the :deep() pseudo class, we are able to tell Vue that this particular class ( .card-title ) should not be scoped....
Read more >Vue.js scoped CSS: learn how can you benefit from it
So, if you ever wondered why is your Vue js scoped style not working, that's probably because you missed the point that the...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@daiwanxing @leafront @LepkoQQ the fix was released in Vite v2.2.3, you should be able to update to it in your projects
You can lock the vite version to 2.1.5 to solve this problem, I tested my local environment and found that this error occurs when the vite version >= 2.2.0