How can I remove `icons.js` from the project
See original GitHub issueI found that icons.js
occupies a large part of the resources. Is there any way to not load this file?
Because I want to reduce the size of the package as much as possible
P.S. I tried to use some components in the form of Vue plugins, but I found it would still be loaded:
import { LayoutPlugin } from "bootstrap-vue";
Vue.use(LayoutPlugin);
Hope you guys can answer my confusion.
Issue Analytics
- State:
- Created 3 years ago
- Reactions:1
- Comments:8 (4 by maintainers)
Top Results From Across the Web
Exclude bootstrap-vue icons with Webpack IgnorePlugin
Here is the way to ignore the icons from bootstrap-vue : new webpack.IgnorePlugin({ resourceRegExp: /\/icons\//, contextRegExp: ...
Read more >How to add and remove icons - Bybrand
In this tutorial, we will look at how to add and remove icons in the HTML email signature with the Bybrand editor -...
Read more >Icons | BootstrapVue
Bootstrap Icons are SVGs, so they scale quickly and easily and can be styled with CSS. While they are built for Bootstrap, they...
Read more >Microstation CE U15-How to remove icons in top right corner?
Hi, We don't want to be "connected." We don't use the Connection Client for anything except licensing. We only have one account per...
Read more >React | Font Awesome Docs
are okay with using SVG + JS to render icons in your project - this react component relies on that technology · Downloaded...
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
"analyzer": "use_analyzer=true npm run serve"
npm run serve
launches a development environment without any tree shaking or minification. You should only analyse a production build.You can do that by using the following script
"build:report": "vue-cli-service build --report",
. This will build your project into thedist
folder, and generate areport.html
file.Here’s the steps i did when trying to reproduce it (i used
yarn
, butnpm
should be the same result).cmd
package.json (added the script i mentioned above, everything else is default)
main.js
App.vue (testing to ensure the LayoutPlugin is installed correctly)
cmd
I believe the icons tree-shaking works most of the time, except under certain circumstances. For example, I found that if I include
SkeletonPlugin
, the icons tree-shaking would fail, so I importBSkeleton
component only and it works.The following is my configuration using Nuxt.
Source: https://code.luasoftware.com/tutorials/vuejs/bootstrapvue-icons-import-specific-icon-only/