mirror of
https://github.com/Redocly/redoc.git
synced 2024-11-25 18:13:44 +03:00
chore: fix demo webpack config
This commit is contained in:
parent
8e5a5e8a83
commit
a3b98177a1
|
@ -24,7 +24,7 @@ const tsLoader = (env) => ({
|
||||||
},
|
},
|
||||||
});
|
});
|
||||||
|
|
||||||
const babelLoader = (mode) => ({
|
const babelLoader = () => ({
|
||||||
loader: 'babel-loader',
|
loader: 'babel-loader',
|
||||||
options: {
|
options: {
|
||||||
generatorOpts: {
|
generatorOpts: {
|
||||||
|
@ -35,13 +35,6 @@ const babelLoader = (mode) => ({
|
||||||
['@babel/plugin-syntax-decorators', { legacy: true }],
|
['@babel/plugin-syntax-decorators', { legacy: true }],
|
||||||
'@babel/plugin-syntax-dynamic-import',
|
'@babel/plugin-syntax-dynamic-import',
|
||||||
'@babel/plugin-syntax-jsx',
|
'@babel/plugin-syntax-jsx',
|
||||||
[
|
|
||||||
'babel-plugin-styled-components',
|
|
||||||
{
|
|
||||||
minify: true,
|
|
||||||
displayName: mode !== 'production',
|
|
||||||
},
|
|
||||||
],
|
|
||||||
]),
|
]),
|
||||||
},
|
},
|
||||||
});
|
});
|
||||||
|
@ -111,7 +104,7 @@ export default (env: { playground?: boolean; bench?: boolean } = {}, { mode }) =
|
||||||
use: compact([
|
use: compact([
|
||||||
mode !== 'production' ? babelHotLoader : undefined,
|
mode !== 'production' ? babelHotLoader : undefined,
|
||||||
tsLoader(env),
|
tsLoader(env),
|
||||||
babelLoader(mode),
|
babelLoader(),
|
||||||
]),
|
]),
|
||||||
exclude: [/node_modules/],
|
exclude: [/node_modules/],
|
||||||
},
|
},
|
||||||
|
|
Loading…
Reference in New Issue
Block a user