]>
Commit | Line | Data |
---|---|---|
64f81bc3 TC |
1 | const path = require('path'); |
2 | const webpack = require('webpack'); | |
3 | const StyleLintPlugin = require('stylelint-webpack-plugin'); | |
4 | ||
5 | const rootDir = path.resolve(__dirname, '../../../'); | |
6 | ||
789c4682 | 7 | module.exports = function () { |
64f81bc3 TC |
8 | return { |
9 | entry: { | |
10 | material: path.join(rootDir, './app/Resources/static/themes/material/index.js'), | |
11 | baggy: path.join(rootDir, './app/Resources/static/themes/baggy/index.js'), | |
12 | }, | |
64f81bc3 TC |
13 | output: { |
14 | filename: '[name].js', | |
15 | path: path.resolve(rootDir, 'web/bundles/wallabagcore'), | |
16 | publicPath: '/bundles/wallabagcore/', | |
17 | }, | |
18 | plugins: [ | |
19 | new webpack.ProvidePlugin({ | |
20 | $: 'jquery', | |
21 | jQuery: 'jquery', | |
22 | 'window.$': 'jquery', | |
789c4682 | 23 | 'window.jQuery': 'jquery', |
64f81bc3 TC |
24 | }), |
25 | new StyleLintPlugin({ | |
26 | configFile: '.stylelintrc', | |
27 | failOnError: false, | |
28 | quiet: false, | |
29 | context: 'app/Resources/static/themes', | |
30 | files: '**/*.scss', | |
31 | }), | |
32 | ], | |
33 | resolve: { | |
34 | alias: { | |
789c4682 JB |
35 | jquery: path.join(rootDir, 'node_modules/jquery/dist/jquery.js'), |
36 | }, | |
64f81bc3 TC |
37 | }, |
38 | }; | |
39 | }; |