socketsupply / socket

A cross-platform runtime for Web developers to build desktop & mobile apps for any OS using any frontend library.
https://socketsupply.co/guides
Other
1.6k stars 75 forks source link

fix(internal/worker): ensure blobs are importable #986

Closed chrisfarms closed 2 months ago

chrisfarms commented 2 months ago

what

attempt to resolve issue #985 , where a Blob url with a missing / non javascript mime type is attempted to be passed to import() during worker spawn.

why

because new Worker(URL.createObjectURL(new Blob([let x = 1;]))) works in browsers and should work in socket too.

note

This fix feels dirty. If there are suggestions for a better place for this fix I will be happy to amend it.

PR against next

jwerle commented 2 months ago

@chrisfarms I have a fix for this about to land in next now!

jwerle commented 2 months ago

fixed in https://github.com/socketsupply/socket/commit/96d8d915318901a50e1954db3123a521812dd0de