Wroclaw
f26206de87
As of today, the vutetify doc states how to install it in the nuxt. So following the guide I did it. Now the website layout does not "jump" with offsets on load.
39 lines
778 B
TypeScript
39 lines
778 B
TypeScript
import { defineNuxtConfig } from "nuxt/config";
|
|
import vuetify, { transformAssetUrls } from 'vite-plugin-vuetify';
|
|
|
|
// https://nuxt.com/docs/api/configuration/nuxt-config
|
|
export default defineNuxtConfig({
|
|
pages: true,
|
|
build: {
|
|
transpile: ["vuetify"],
|
|
},
|
|
modules: [
|
|
(_options, nuxt) => {
|
|
nuxt.hooks.hook('vite:extendConfig', (config) => {
|
|
config.plugins?.push(vuetify({ autoImport: true }));
|
|
});
|
|
},
|
|
],
|
|
css: [
|
|
"vuetify/lib/styles/main.sass",
|
|
"@mdi/font/css/materialdesignicons.min.css",
|
|
],
|
|
ssr: true,
|
|
nitro: {
|
|
esbuild: {
|
|
options: {
|
|
target: "es2022",
|
|
},
|
|
},
|
|
},
|
|
vite: {
|
|
vue: {
|
|
template: {
|
|
transformAssetUrls,
|
|
},
|
|
},
|
|
},
|
|
imports: {
|
|
autoImport: false,
|
|
},
|
|
});
|