mirror of
https://github.com/hasura/graphql-engine.git
synced 2024-12-17 20:41:49 +03:00
15 lines
388 B
JavaScript
15 lines
388 B
JavaScript
|
const { merge } = require('webpack-merge');
|
||
|
const dynamicAssetLoader = require('unplugin-dynamic-asset-loader');
|
||
|
|
||
|
module.exports =
|
||
|
() =>
|
||
|
(config, { options, context }) => {
|
||
|
const isDevBuild = context.configurationName === 'development';
|
||
|
if (!isDevBuild) {
|
||
|
return config;
|
||
|
}
|
||
|
return merge(config, {
|
||
|
plugins: [dynamicAssetLoader.webpackPlugin()],
|
||
|
});
|
||
|
};
|