mirror of
https://github.com/GoogleChromeLabs/squoosh.git
synced 2025-11-14 09:39:15 +00:00
Get rid of DeprecationWarning output filter
This commit is contained in:
@@ -12,12 +12,6 @@ const CopyPlugin = require('copy-webpack-plugin');
|
|||||||
const WatchTimestampsPlugin = require('./config/watch-timestamps-plugin');
|
const WatchTimestampsPlugin = require('./config/watch-timestamps-plugin');
|
||||||
const BundleAnalyzerPlugin = require('webpack-bundle-analyzer').BundleAnalyzerPlugin;
|
const BundleAnalyzerPlugin = require('webpack-bundle-analyzer').BundleAnalyzerPlugin;
|
||||||
|
|
||||||
const oldWrite = process.stderr.write;
|
|
||||||
process.stderr.write = chunk => {
|
|
||||||
if (String(chunk).indexOf('DeprecationWarning:')!==-1) return;
|
|
||||||
return oldWrite.call(process.stderr, chunk);
|
|
||||||
};
|
|
||||||
|
|
||||||
function parseJson(text, fallback) {
|
function parseJson(text, fallback) {
|
||||||
try {
|
try {
|
||||||
return JSON.parse(text);
|
return JSON.parse(text);
|
||||||
|
|||||||
Reference in New Issue
Block a user