Skip to content
This repository was archived by the owner on May 8, 2025. It is now read-only.
This repository was archived by the owner on May 8, 2025. It is now read-only.

CLI build production - Vuetify CSS is merged after Vue component(s) CSS #4

@mikekidder

Description

@mikekidder

Currently the plugin is setup to inject the Vuetify import(s) after all others in main.js/main.ts file.
The Vuetify CSS is merged after the Vue component(s) styles, when you do a production build.

Ran into issue where some style elements weren't being applied to components. Its the order of things.

I resolved by shuffling the imports like so:

import Vue from 'vue'
import './registerServiceWorker'
import Vuetify from 'vuetify'
import 'vuetify/dist/vuetify.min.css'

import App from './App.vue'

Vue.use(Vuetify)

Vue.config.productionTip = false

new Vue({
  render: h => h(App)
}).$mount('#app')

Having the vuetify css import anywhere before the App import resolves.
NOTE: Order is not an issue if your .vue file components style blocks are scoped.

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions