@nitro-web/webpack 0.0.142 → 0.0.144
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/types/webpack.config.d.ts.map +1 -1
- package/webpack.config.js +10 -0
package/package.json
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"webpack.config.d.ts","sourceRoot":"","sources":["../webpack.config.js"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"webpack.config.d.ts","sourceRoot":"","sources":["../webpack.config.js"],"names":[],"mappings":"AAyCO,yCAOG,QAAG,EAAE,SAAI;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAuRlB"}
|
package/webpack.config.js
CHANGED
|
@@ -28,6 +28,16 @@ const nitroVersion = _require('./package.json').version
|
|
|
28
28
|
// retryCondition: (e) => e.code == 'ECONNREFUSED',
|
|
29
29
|
// })
|
|
30
30
|
|
|
31
|
+
// Patch console.warn to stop optimizeUniversalDefaults polluting output during bundling.
|
|
32
|
+
// https://github.com/tailwindlabs/tailwindcss/blob/v3/src/featureFlags.js#L55
|
|
33
|
+
// https://github.com/tailwindlabs/tailwindcss/blob/v3/src/util/log.js#L12
|
|
34
|
+
const warnOriginal = console.warn
|
|
35
|
+
console.warn = (arg1, arg2, arg3, ...args) => {
|
|
36
|
+
if (!arg1) return // remove empty console.warn
|
|
37
|
+
else if (typeof arg3 === 'string' && arg3.match(/experimental/i)) return // remove main messages
|
|
38
|
+
else warnOriginal(arg1, arg2, arg3, ...args)
|
|
39
|
+
}
|
|
40
|
+
|
|
31
41
|
// process.traceDeprecation = true
|
|
32
42
|
export const getConfig = (config) => {
|
|
33
43
|
const { client, name='', pwd, env='development', homepage, publicPath, version } = config
|