mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-07-13 16:16:46 +08:00
refactor: webpack config (#11421)
This commit is contained in:
Vendored
+1
@@ -17,6 +17,7 @@ export function setupGlobal() {
|
||||
isMobile: false,
|
||||
isSelfHosted: false,
|
||||
publicPath: '/',
|
||||
workerPath: '/js/',
|
||||
};
|
||||
|
||||
if (globalThis.navigator) {
|
||||
|
||||
Vendored
+7
@@ -0,0 +1,7 @@
|
||||
export function getWorkerUrl(name: string) {
|
||||
if (BUILD_CONFIG.debug && !name.endsWith('.worker.js')) {
|
||||
throw new Error(`worker should be named with '.worker.js', get ${name}`);
|
||||
}
|
||||
|
||||
return environment.workerPath + name + '?v=' + BUILD_CONFIG.appVersion;
|
||||
}
|
||||
Reference in New Issue
Block a user