You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Since bundled script (via webpack 4) is loaded in worker, I suppose, window.location.search is undefined
Here is webpack added stuff and last line crashes
'use strict';
/* global __resourceQuery WorkerGlobalScope self */
/* eslint prefer-destructuring: off */
var url = require('url');
var stripAnsi = require('strip-ansi');
var log = require('loglevel').getLogger('webpack-dev-server');
var socket = require('./socket');
var overlay = require('./overlay');
function getCurrentScriptSource() {
// `document.currentScript` is the most accurate way to find the current script,
// but is not supported in all browsers.
if (document.currentScript) {
return document.currentScript.getAttribute('src');
}
// Fall back to getting all scripts in the document.
var scriptElements = document.scripts || [];
var currentScript = scriptElements[scriptElements.length - 1];
if (currentScript) {
return currentScript.getAttribute('src');
}
// Fail as there was no script to use.
throw new Error('[WDS] Failed to get current script source.');
}
var urlParts = void 0;
var hotReload = true;
if (typeof window !== 'undefined') {
var qs = window.location.search.toLowerCase();
The text was updated successfully, but these errors were encountered:
window.location.search is no longer undefined but it returns WorkerLocation.search which is not the expected value. We'll need to hydrate this from the main thread for read access. Writing is another matter.
Since bundled script (via webpack 4) is loaded in worker, I suppose, window.location.search is undefined
Here is webpack added stuff and last line crashes
The text was updated successfully, but these errors were encountered: