You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[BridgeJS] wasm-ld: error: import module mismatch for symbol #657
That means currently BridgeJS cannot be used in libraries, because linking the final wasm binary (especially in embedded) will cause errors like this one.
wasm-ld: error: import module mismatch for symbol: $e14BrowserInterop36bjs_JSWindow_getComputedStyle_extern33_A850048D7CA460B221AE34673489EEABLLys5Int32VAE_AEtF
>>> defined as env in /Users/simon/dev/elementary-swift/elementary-ui/Examples/Basic/.build/wasm32-unknown-wasip1/release/App.build/AnimationsView.swift.o
>>> defined as BrowserInterop in /Users/simon/dev/elementary-swift/elementary-ui/Examples/Basic/.build/wasm32-unknown-wasip1/release/BrowserInterop.build/BridgeJS.swift.o
wasm-ld: error: import module mismatch for symbol: $e14BrowserInterop28bjs_JSPerformance_now_extern33_A850048D7CA460B221AE34673489EEABLLySds5Int32VF
>>> defined as env in /Users/simon/dev/elementary-swift/elementary-ui/Examples/Basic/.build/wasm32-unknown-wasip1/release/App.build/AnimationsView.swift.o
>>> defined as BrowserInterop in /Users/simon/dev/elementary-swift/elementary-ui/Examples/Basic/.build/wasm32-unknown-wasip1/release/BrowserInterop.build/BridgeJS.swift.o
wasm-ld: error: import module mismatch for symbol: $e14BrowserInterop019make_swift_closure_ab3_14aB11Sd_y_extern33_A850048D7CA460B221AE34673489EEABLLys5Int32VSv_SPys5UInt8VGs6UInt32VtF
>>> defined as env in /Users/simon/dev/elementary-swift/elementary-ui/Examples/Basic/.build/wasm32-unknown-wasip1/release/App.build/AnimationsView.swift.o
>>> defined as bjs in /Users/simon/dev/elementary-swift/elementary-ui/Examples/Basic/.build/wasm32-unknown-wasip1/release/BrowserInterop.build/BridgeJS.swift.o
Unfortunately, we don't have workaround for Embedded build mode because it always serialize everything into swiftmodule and emit code in the client's object files.
Activity
kateinoigakukun commentedon Feb 19, 2026
This is super unfortunate but let me apply workarounds until we get the toolchain fix
Amzd commentedon Feb 21, 2026
This same issue (I think) is now occurring with different symbols:
kateinoigakukun commentedon Feb 21, 2026
@Amzd Take 2 #670 🙏
kateinoigakukun commentedon Feb 21, 2026
https://github.com/swiftwasm/JavaScriptKit/releases/tag/0.46.2 fixed it
Amzd commentedon Feb 21, 2026
You are fantastic!
sliemeobn commentedon Feb 21, 2026
@kateinoigakukun it pains me to say this, but this is still not working in ElementaryUI with
0.46.2I published my WIP branch here:
elementary-swift/elementary-ui#76
I still get a lot of errors like this:
kateinoigakukun commentedon Feb 21, 2026
Unfortunately, we don't have workaround for Embedded build mode because it always serialize everything into swiftmodule and emit code in the client's object files.
sliemeobn commentedon Feb 21, 2026
I don't quite understand why the other symbols work. Like the built-in BridgeJS funcs for example? 🤔
kateinoigakukun commentedon Feb 22, 2026
Hmm, good point. I'll keep focusing on landing the root cause fix but let me know if you could find a workaround
sliemeobn commentedon Mar 3, 2026
just to summarize:
BridgeJS does not (and most likely will never) work for Embedded Swift on 6.2
this issue seems resolved with the latest 6.3 and main snapshots (with @kateinoigakukun 's fix)