forked from MusheAbdulHakim/Laravel-Smarthr
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathvite.config.js
33 lines (30 loc) · 892 Bytes
/
vite.config.js
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
import { defineConfig } from "vite";
import laravel from "laravel-vite-plugin";
import collectModuleAssetsPaths from "./vite-module-loader.js";
async function getConfig() {
const paths = [
"resources/css/app.scss",
"resources/assets/scss/main.scss",
"resources/js/app.js",
"resources/js/datatables.js",
"resources/js/ckeditor.js",
"resources/js/app/chat/chat-app.js",
];
const allPaths = await collectModuleAssetsPaths(paths, "Modules");
return defineConfig({
plugins: [
laravel({
input: allPaths,
refresh: true,
}),
],
define: {
"process.env.IS_PREACT": JSON.stringify("true"),
},
optimizeDeps: {
exclude: ["js-big-decimal"],
},
assetsInlineLimit: 0
});
}
export default getConfig();