forked from Blair2004/NexoPOS
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathwebpack.mix.js
executable file
·47 lines (42 loc) · 1.9 KB
/
webpack.mix.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
34
35
36
37
38
39
40
41
42
43
44
45
46
47
const tailwindcss = require('tailwindcss');
const path = require( 'path' );
const mix = require( 'laravel-mix' );
/*
|--------------------------------------------------------------------------
| Mix Asset Management
|--------------------------------------------------------------------------
|
| Mix provides a clean, fluent API for defining some Webpack build steps
| for your Laravel application. By default, we are compiling the Sass
| file for the application as well as bundling up all the JS files.
|
*/
mix
.webpackConfig({
resolve: {
extensions: [ ".vue", ".ts" ],
alias: {
'@': path.resolve( __dirname, 'resources/ts/')
}
}
});
mix.disableNotifications();
mix.extract();
mix.vue({ version: 2 })
if ( mix.inProduction() ) {
mix.version();
} else {
mix.sourceMaps();
}
mix
.ts( 'resources/ts/bootstrap.ts', mix.inProduction() ? 'public/js/bootstrap.min' : 'public/js')
.ts( 'resources/ts/lang-loader.ts', mix.inProduction() ? 'public/js/lang-loader.min' : 'public/js')
.ts( 'resources/ts/app.ts', mix.inProduction() ? 'public/js/app.min' : 'public/js')
.ts( 'resources/ts/dashboard.ts', mix.inProduction() ? 'public/js/dashboard.min' : 'public/js')
.ts( 'resources/ts/cashier.ts', mix.inProduction() ? 'public/js/cashier.min' : 'public/js')
.ts( 'resources/ts/update.ts', mix.inProduction() ? 'public/js/update.min' : 'public/js')
.ts( 'resources/ts/pos-init.ts', mix.inProduction() ? 'public/js/pos-init.min' : 'public/js')
.ts( 'resources/ts/pos.ts', mix.inProduction() ? 'public/js/pos.min' : 'public/js')
.ts( 'resources/ts/auth.ts', mix.inProduction() ? 'public/js/auth.min' : 'public/js')
.ts( 'resources/ts/setup.ts', mix.inProduction() ? 'public/js/setup.min' : 'public/js')
.ts( 'resources/ts/popups.ts', mix.inProduction() ? 'public/js/popups.min' : 'public/js/' )