Skip to content

Parcel 2 compatibility #319

@lgarron

Description

@lgarron

I've been scratching my head about how to build compatible workers, and this library is the most promising so far! Unfortunately, I use Parcel 2, and the basic demo runs into an error. 😢

auth.bd78dd40.js:1 Uncaught DOMException: Failed to execute 'importScripts' on 'WorkerGlobalScope': The URL './index.d6afe8b1.js' is invalid.
    at http://localhost:1234/auth.bd78dd40.js:1:1
    at blob:http://localhost:1234/13b36260-4ae6-4c43-845c-0dfccc529f9c:1:1

I thought I found a reference suggesting that you can't use this kind of relative path from a blob, but Parcel 2 can definitely handle workers in general (e.g. libraries like comlink work with parcel server). However, I can't seem to find that again.

I'd really like to use threads.js, but this is a big blocker for our use case. Any thoughts on where best to attempt to address this?

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions