feat: 🎸 Add a shared service between web workers (#2932)

* feat: 🎸 Add a shared service between web workers

✅ Closes: https://hashicorp.atlassian.net/browse/ICU-17409
This commit is contained in:
Zhihe Li committed 2025-09-03 11:41:40 -04:00
1 parent a9a6518b23
commit 8abed1a809
7 files changed
+326 -37

No files matched your search

+2 -2
View File
@@ -21,7 +21,7 @@ export default class SqliteDbService extends Service {
return;
}
// In production, our JS files will be fingerprinted with am MD5 hash
// In production, our JS files will be fingerprinted with an MD5 hash
// so we need a way to map the worker file name to be able to find it.
//
// Ember is automagically replacing any URL path with the fingerprinted
@@ -31,7 +31,7 @@ export default class SqliteDbService extends Service {
// https://github.com/ember-cli/broccoli-asset-rewrite/issues/66
// and will not work properly if it's part of a template string or interpolated.
// Therefore, we need the URL path in a string somewhere to be replaced properly.
this.webWorker = new Worker('/workers/web-worker.js', {
this.webWorker = new Worker('/workers/sqlite-worker.js', {
type: 'module',
});