mirror of
https://github.com/titaniumnetwork-dev/Ultraviolet.git
synced 2025-05-16 21:10:02 -04:00
fix parse5 sourcemap warnings
This commit is contained in:
parent
e891c6a831
commit
a9c94002ae
1 changed files with 11 additions and 3 deletions
|
@ -28,13 +28,21 @@ const config = {
|
||||||
module: {
|
module: {
|
||||||
rules: [
|
rules: [
|
||||||
{
|
{
|
||||||
test: /\.js$/,
|
test: /\.(js|mjs)$/,
|
||||||
enforce: 'pre',
|
enforce: 'pre',
|
||||||
use: ['source-map-loader'],
|
use: [
|
||||||
|
{
|
||||||
|
loader: 'source-map-loader',
|
||||||
|
options: {
|
||||||
|
filterSourceMappingUrl: (url, resourcePath) =>
|
||||||
|
// parse5 references sourcemaps but doesn't publish them
|
||||||
|
!resourcePath.includes('parse5'),
|
||||||
|
},
|
||||||
|
},
|
||||||
|
],
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
},
|
},
|
||||||
ignoreWarnings: [/Failed to parse source map/],
|
|
||||||
optimization: {
|
optimization: {
|
||||||
minimize: !isDevelopment,
|
minimize: !isDevelopment,
|
||||||
minimizer: [
|
minimizer: [
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue