three_base/vite.config.js
2022-03-15 11:50:37 +08:00

33 lines
589 B
JavaScript

import {
defineConfig
} from 'vite'
import vue from '@vitejs/plugin-vue'
import glsl from 'vite-plugin-glsl'
import path from 'path'
const nodeResolve = (dir) => path.resolve(__dirname, '.', dir)
// https://vitejs.dev/config/
export default defineConfig({
resolve: {
alias: {
'@': nodeResolve('src')
},
},
server: {
host: '0.0.0.0',
port: 3000,
},
css: {
preprocessorOptions: {
scss: {
additionalData: `@import "@/style/variables.scss";`,
javascriptEnabled: true,
},
},
},
plugins: [
vue(),
glsl(),
]
})