-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathvite.config.js
More file actions
37 lines (36 loc) · 892 Bytes
/
vite.config.js
File metadata and controls
37 lines (36 loc) · 892 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
import {resolve} from 'path';
import {defineConfig} from 'vite';
import vue from '@vitejs/plugin-vue';
import i18nExtractKeys from './i18nExtractKeys.vite.js';
export default defineConfig({
plugins: [
i18nExtractKeys({
extraKeys: [
'plugins.generic.thoth.workStatus.active',
'plugins.generic.thoth.workStatus.forthcoming',
'plugins.generic.thoth.workStatus.withdrawn',
'plugins.generic.thoth.workStatus.superseded',
'plugins.generic.thoth.workStatus.postponedIndefinitely',
'plugins.generic.thoth.workStatus.cancelled',
],
}),
vue(),
],
build: {
lib: {
entry: resolve(__dirname, 'resources/js/main.js'),
name: 'ThothPlugin',
fileName: 'build',
formats: ['iife'],
},
outDir: resolve(__dirname, 'public/build'),
rollupOptions: {
external: ['vue'],
output: {
globals: {
vue: 'pkp.modules.vue',
},
},
},
},
});