sqlite-worker icon indicating copy to clipboard operation
sqlite-worker copied to clipboard

Unable to use worker in a WebExtension

Open jobisoft opened this issue 10 months ago • 2 comments

Foremost, thanks for this awesome project. We created an example Thunderbird WebExtension, to show how it can be used: https://github.com/thunderbird/webext-examples/tree/master/manifest_v2/indexdb.sql

While creating the example, I could not load the module as an actual worker, but had to bootstrap the SQLiteWorker module into the main thread: https://github.com/thunderbird/webext-examples/blob/master/manifest_v2/indexdb.sql/background.js#L11-L22

I think using this as a real worker will be better performance-wise. Do you have any idea of what I missed or did wrong?

jobisoft avatar Jan 11 '25 11:01 jobisoft

I think you’re better off with sql.js: https://github.com/WebReflection/sql.js

WebReflection avatar Jan 11 '25 12:01 WebReflection

I will give it a try and report back!

jobisoft avatar Jan 11 '25 13:01 jobisoft