mirror of
https://github.com/FrankerFaceZ/FrankerFaceZ.git
synced 2025-07-25 03:58:30 +00:00
Maintenance: Fixing build issues for the bundled browser extension.
This commit is contained in:
parent
f88f859dcf
commit
459e77a2a3
4 changed files with 7 additions and 5 deletions
|
@ -6,7 +6,7 @@
|
||||||
return;
|
return;
|
||||||
|
|
||||||
const HOST = location.hostname,
|
const HOST = location.hostname,
|
||||||
SERVER = browser.runtime.getURL("web/"),
|
SERVER = browser.runtime.getURL("web"),
|
||||||
script = document.createElement('script');
|
script = document.createElement('script');
|
||||||
|
|
||||||
let FLAVOR =
|
let FLAVOR =
|
||||||
|
@ -22,5 +22,6 @@
|
||||||
script.crossOrigin = 'anonymous';
|
script.crossOrigin = 'anonymous';
|
||||||
script.src = `${SERVER}/${FLAVOR}.js?_=${Date.now()}`;
|
script.src = `${SERVER}/${FLAVOR}.js?_=${Date.now()}`;
|
||||||
script.dataset.path = SERVER;
|
script.dataset.path = SERVER;
|
||||||
|
|
||||||
document.head.appendChild(script);
|
document.head.appendChild(script);
|
||||||
})();
|
})();
|
||||||
|
|
|
@ -21,8 +21,6 @@ import {has} from 'utilities/object';
|
||||||
|
|
||||||
import MAIN_URL from 'site/styles/main.scss';
|
import MAIN_URL from 'site/styles/main.scss';
|
||||||
|
|
||||||
console.log('!!!!!!!! MAIN_URL: !!!!!!!!!', MAIN_URL);
|
|
||||||
|
|
||||||
|
|
||||||
// ============================================================================
|
// ============================================================================
|
||||||
// The Site
|
// The Site
|
||||||
|
|
|
@ -6,8 +6,9 @@ import {make_enum} from 'utilities/object';
|
||||||
export const DEBUG = localStorage.ffzDebugMode === 'true' && document.body.classList.contains('ffz-dev');
|
export const DEBUG = localStorage.ffzDebugMode === 'true' && document.body.classList.contains('ffz-dev');
|
||||||
export const EXTENSION = !!__extension__;
|
export const EXTENSION = !!__extension__;
|
||||||
export const SERVER = DEBUG ? '//localhost:8000' : 'https://cdn.frankerfacez.com';
|
export const SERVER = DEBUG ? '//localhost:8000' : 'https://cdn.frankerfacez.com';
|
||||||
|
|
||||||
export const SERVER_OR_EXT = EXTENSION
|
export const SERVER_OR_EXT = EXTENSION
|
||||||
? __extension__
|
? __webpack_public_path__
|
||||||
: `${SERVER}/script`;
|
: `${SERVER}/script`;
|
||||||
|
|
||||||
export const CLIENT_ID = 'a3bc9znoz6vi8ozsoca0inlcr4fcvkl';
|
export const CLIENT_ID = 'a3bc9znoz6vi8ozsoca0inlcr4fcvkl';
|
||||||
|
|
|
@ -175,7 +175,9 @@ const config = {
|
||||||
include: /src/,
|
include: /src/,
|
||||||
type: 'asset/resource',
|
type: 'asset/resource',
|
||||||
generator: {
|
generator: {
|
||||||
filename: '[name].[contenthash:8].json'
|
filename: (FOR_EXTENSION || DEV_BUILD)
|
||||||
|
? '[name].json'
|
||||||
|
: '[name].[contenthash:8].json'
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue