mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-02-14 13:25:12 +00:00
refactor(core): add version in worker url (#11614)
Co-authored-by: renovate <29139614+renovate@users.noreply.github.com>
This commit is contained in:
8
packages/common/env/src/worker.ts
vendored
8
packages/common/env/src/worker.ts
vendored
@@ -1,7 +1,5 @@
|
||||
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;
|
||||
return (
|
||||
environment.workerPath + `${name}-${BUILD_CONFIG.appVersion}.worker.js`
|
||||
);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user