import webpack from 'webpack'; import HtmlWebpackPlugin from 'html-webpack-plugin'; import autoprefixer from 'autoprefixer'; import htmlWebpackTemplate from 'html-webpack-template'; export const commonRules: webpack.RuleSetRule[] = [ { test: /\.css$/, use: ['style-loader', 'css-loader'], }, { test: /\.(scss)$/, use: [ 'style-loader', 'css-loader', { loader: 'postcss-loader', options: { plugins: function () { return [autoprefixer]; }, }, }, 'sass-loader', ], }, { test: /\.(png|jpe?g|gif|svg|woff|woff2|ttf|eot)$/i, use: [ { loader: 'url-loader', options: { limit: 8192, }, }, ], }, ]; export const htmlCommonConfig: HtmlWebpackPlugin.Options = { inject: false, template: htmlWebpackTemplate, appMountId: 'app', mobile: true, headHtmlSnippet: ` `, title: 'Timeline', };