bootstrap-vue will purged
See original GitHub issueHi, I’m trying to use purgecss with bootstrap-vue… I read about this in several related issues, but, I can not be successful.
purgeCSS: {
mode: 'postcss',
paths: [
'components/**/*.vue',
'layouts/**/*.vue',
'pages/**/*.vue',
'plugins/**/*.js',
'node_modules/bootstrap-vue/es/**/**/*.js',
'node_modules/bootstrap-vue/**/*.js'
],
styleExtensions: ['.css'],
whitelist: ['body', 'html', 'nuxt-progress', 'navbar'],
whitelistPatterns: [/^b-/, /nav/]
},
build: {
extractCSS: true,
...
}
index.vue
<template>
<div>
<b-navbar
toggleable="md"
type="dark"
variant="info">
<b-navbar-toggle target="nav_collapse"/>
<b-navbar-brand href="#">NavBar</b-navbar-brand>
<b-collapse
id="nav_collapse"
is-nav>
<b-navbar-nav>
<b-nav-item href="#">Link</b-nav-item>
<b-nav-item
href="#"
disabled>Disabled</b-nav-item>
</b-navbar-nav>
<!-- Right aligned nav items -->
<b-navbar-nav class="ml-auto">
<b-nav-form>
<b-form-input
size="sm"
class="mr-sm-2"
type="text"
placeholder="Search"/>
<b-button
size="sm"
class="my-2 my-sm-0"
type="submit">Search</b-button>
</b-nav-form>
<b-nav-item-dropdown
text="Lang"
right>
<b-dropdown-item href="#">EN</b-dropdown-item>
<b-dropdown-item href="#">ES</b-dropdown-item>
<b-dropdown-item href="#">RU</b-dropdown-item>
<b-dropdown-item href="#">FA</b-dropdown-item>
</b-nav-item-dropdown>
<b-nav-item-dropdown right>
<!-- Using button-content slot -->
<template slot="button-content">
<em>User</em>
</template>
<b-dropdown-item href="#">Profile</b-dropdown-item>
<b-dropdown-item href="#">Signout</b-dropdown-item>
</b-nav-item-dropdown>
</b-navbar-nav>
</b-collapse>
</b-navbar>
</div>
</template>
could anyone help me?
thanks.
Issue Analytics
- State:
- Created 5 years ago
- Comments:13 (2 by maintainers)
Top Results From Across the Web
vue.js - How do I whitelist everything I need for BootstrapVue ...
In an attempt to solve this, I installed nuxt-purgecss in the hope that it would extract all unused css from bootstrap.css, and bootstrap-vue....
Read more >Is bootstrap-vue dead? : r/vuejs - Reddit
BootstrapVue was a legitimate solution for Vue 2 and Bootstrap 4 as they would not work together well out of the box.
Read more >Optimizing CSS with PurgeCSS | Warren Lee
I think one thing you can try is to reduce the amount of unused CSS when you're using a type of Vue/CSS framework...
Read more >[Solved]-How to stop BootstrapVue carousel cycling?-Vue.js
From bootstrap-vue docs: To pause the carousel from auto sliding, set the interval prop to 0. To restart a paused carousel, set the...
Read more >How to add Tailwind CSS, Bootstrap ... - DEV Community
In this tutorial, we will discuss how to add a CSS Framework to a Vue ... tailwind.config.js module.exports = { purge: [], darkMode:...
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
I’m using tailwindcss instead of bootstrap now.
Any update on this? I have the same problem with element ui in a nuxtJS project