source: gs3-installations/atea/trunk/interfaces/atea/ocr/vite.config.js@ 36874

Last change on this file since 36874 was 36874, checked in by cstephen, 18 months ago

Migrate ocr project to vite

File size: 875 bytes
Line 
1import babel from '@rollup/plugin-babel';
2import vue from '@vitejs/plugin-vue'
3import { fileURLToPath, URL } from 'node:url'
4import { defineConfig } from 'vite'
5
6// https://vitejs.dev/config/
7export default defineConfig({
8 base: process.env.NODE_ENV === 'production'
9 ? '/greenstone3/interfaces/atea/ocr/dist/'
10 : '/',
11 plugins: [
12 vue()
13 ],
14 resolve: {
15 alias: {
16 '@': fileURLToPath(new URL('./src', import.meta.url))
17 }
18 },
19 build: {
20 rollupOptions: {
21 output: {
22 entryFileNames: "[name].js"
23 },
24 plugins: [babel({ babelHelpers: "bundled" })]
25 }
26 },
27 css: {
28 preprocessorOptions: {
29 scss: {
30 additionalData: "@use \"@/styles/_material.scss\";@use \"@/styles/theme.scss\";"
31 }
32 }
33 }
34})
Note: See TracBrowser for help on using the repository browser.