You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
42 lines
866 B
TypeScript
42 lines
866 B
TypeScript
import { fileURLToPath, URL } from 'node:url'
|
|
import { defineConfig } from 'vite'
|
|
import vue from '@vitejs/plugin-vue'
|
|
import vueJsx from '@vitejs/plugin-vue-jsx'
|
|
import glsl from 'vite-plugin-glsl'
|
|
import svgLoader from 'vite-svg-loader'
|
|
|
|
const isGithubView = process.env.VITE_APP_VIEW === 'github'
|
|
|
|
export default defineConfig({
|
|
base: isGithubView ? '/lightdm-webkit-theme-osmos/' : '/',
|
|
plugins: [
|
|
vue(),
|
|
vueJsx(),
|
|
glsl(),
|
|
svgLoader({
|
|
svgoConfig: {
|
|
plugins: [
|
|
{
|
|
name: 'preset-default',
|
|
params: {
|
|
overrides: {
|
|
removeViewBox: false
|
|
}
|
|
}
|
|
}
|
|
]
|
|
}
|
|
})
|
|
],
|
|
resolve: {
|
|
alias: {
|
|
'@': fileURLToPath(new URL('./src', import.meta.url))
|
|
}
|
|
},
|
|
css: {
|
|
preprocessorOptions: {
|
|
stylus: {}
|
|
}
|
|
}
|
|
})
|