mirror of
https://github.com/OpenXE-org/OpenXE.git
synced 2024-12-28 15:40:28 +01:00
30 lines
718 B
JavaScript
30 lines
718 B
JavaScript
// SPDX-FileCopyrightText: 2023 Andreas Palm
|
|
//
|
|
// SPDX-License-Identifier: AGPL-3.0-only
|
|
|
|
import glob from 'glob';
|
|
import path from 'path';
|
|
import vue from '@vitejs/plugin-vue';
|
|
|
|
const moduleInputs = glob.sync('classes/Modules/*/www/js/entry.{js,jsx}')
|
|
.map(file => ['modules/'+file.split('/')[2], file]);
|
|
|
|
/** @type {import('vite').UserConfig} */
|
|
export default {
|
|
build: {
|
|
rollupOptions: {
|
|
input: {
|
|
...Object.fromEntries(moduleInputs)
|
|
}
|
|
},
|
|
manifest: true,
|
|
outDir: 'www/dist',
|
|
},
|
|
plugins: [vue()],
|
|
mode: 'development',
|
|
resolve: {
|
|
alias: {
|
|
'@res': path.resolve(__dirname, 'resources')
|
|
}
|
|
}
|
|
} |