mirror of
https://github.com/scratchfoundation/scratch-desktop.git
synced 2024-12-22 13:42:27 -05:00
78d75dc3cf
Instead of overriding rules we don't want by matching the test exactly, we now explicitly delete rules we don't want before adding any of our custom rules.
24 lines
738 B
JavaScript
24 lines
738 B
JavaScript
const path = require('path');
|
|
|
|
const CopyWebpackPlugin = require('copy-webpack-plugin');
|
|
|
|
const makeConfig = require('./webpack.makeConfig.js');
|
|
|
|
module.exports = defaultConfig =>
|
|
makeConfig(
|
|
defaultConfig,
|
|
{
|
|
name: 'renderer',
|
|
useReact: true,
|
|
disableDefaultRulesForExtensions: ['js', 'jsx', 'css', 'svg', 'png', 'wav', 'gif', 'jpg'],
|
|
babelPaths: [
|
|
path.resolve(__dirname, 'src', 'renderer')
|
|
],
|
|
plugins: [
|
|
new CopyWebpackPlugin([{
|
|
from: path.resolve(__dirname, 'node_modules', 'scratch-gui', 'dist', 'static'),
|
|
to: 'static'
|
|
}])
|
|
]
|
|
}
|
|
);
|