* Set dynamically aboslute public path on 'npm run watch'; fix http/https hardcoded in watch.js * WEBPACK_PUBLIC_PATH fix
9 lines
298 B
JavaScript
9 lines
298 B
JavaScript
/* globals WEBPACK_PUBLIC_PATH */
|
|
|
|
// Dynamically set absolute public path from current protocol and host
|
|
if (WEBPACK_PUBLIC_PATH !== false) {
|
|
/* eslint-disable no-undef */
|
|
__webpack_public_path__ = location.protocol + '//' + location.host + WEBPACK_PUBLIC_PATH;
|
|
/*eslint-enable no-undef*/
|
|
}
|