12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849 |
- const path = require("path");
- const MiniCssExtractPlugin = require("mini-css-extract-plugin");
- const babylonWebpackConfig = require('../Tools/WebpackPlugins/babylonWebpackConfig');
- var config = babylonWebpackConfig({
- module: "inspector",
- resolve: {
- extensions: [".js", '.ts', ".tsx"],
- alias: {
- "re-resizable$": __dirname + "/../node_modules/re-resizable/lib/index.es5.js"
- }
- },
- moduleRules: [
- {
- test: /\.scss$/,
- use: [
- // fallback to style-loader in development
- process.env.NODE_ENV !== 'production' ? 'style-loader' : MiniCssExtractPlugin.loader,
- "css-loader",
- "sass-loader"
- ]
- },
- {
- test: /\.css$/,
- use: ['style-loader', 'css-loader']
- },
- {
- test: /\.svg$/,
- use: [
- {
- loader: 'svg-url-loader',
- options: {
- limit: 10000,
- },
- },
- ],
- }
- ],
- plugins: [
- new MiniCssExtractPlugin({
- // Options similar to the same options in webpackOptions.output
- // both options are optional
- filename: "[name].css",
- chunkFilename: "[id].css"
- })
- ]
- });
- module.exports = config;
|