Erant-OldApp/vite.config.js

33 lines
679 B
JavaScript
Raw Normal View History

2022-12-01 11:25:45 +00:00
import { defineConfig } from 'vite'
import { svelte } from '@sveltejs/vite-plugin-svelte'
import preprocess from "svelte-preprocess"
import path from 'path'
2022-12-04 14:58:31 +00:00
// https://vitejs.dev/config/
export default defineConfig({
2022-12-01 11:25:45 +00:00
resolve: {
alias: {
'$lib': path.resolve(__dirname, 'src', 'lib'),
'$root': path.resolve(__dirname),
'$src': path.resolve(__dirname, 'src'),
2022-12-03 21:35:28 +00:00
'$cms': path.resolve(__dirname, 'cms')
2022-12-01 11:25:45 +00:00
}
},
plugins: [
svelte({
preprocess: preprocess({
scss: true,
postcss: true
})
})
2022-12-04 14:58:31 +00:00
],
build: {
rollupOptions: {
input: {
app: path.resolve(__dirname, 'index.html'),
cms: path.resolve(__dirname, 'cms', 'index.html')
}
}
}
})