Is Compose Navigation expected to work on WASM? M...
# compose-web
c
Is Compose Navigation expected to work on WASM? My app loads a landing page, which is a default navigation destination. But as soon as I click a button to navigate further, the WASM target crashes across all three major browsers. This currently happens with Kotlin 2.2.10 and Compose 1.9.0-beta03, but this is not a regression. Its not worked for me with prior Compose releases. The same navigation works OK in the Android and Desktop targets.
👌 2
The stacktrace is quite long—it starts off looking like this
Copy code
func21503	@	60ef477….wasm:0x34ceee
$func22236	@	60ef477….wasm:0x35d398
$func15168	@	60ef477….wasm:0x2c1a9e
$func15154	@	60ef477….wasm:0x2c164f
$func15155	@	60ef477….wasm:0x2c16a4
$__callFunction___Double_->Unit_	@	60ef477….wasm:0x20f2a9
(anonymous)	@	client-app.uninstantiated.mjs:225
requestAnimationFrame		
org.jetbrains.skiko.w3c.requestAnimationFrame_$external_fun	@	client-app.uninstantiated.mjs:379
$func15178	@	60ef477….wasm:0x2c1b90
$func15159	@	60ef477….wasm:0x2c1847
$func15170	@	60ef477….wasm:0x2c1ad8
$func22238	@	60ef477….wasm:0x35d3c4
$func22239	@	60ef477….wasm:0x35d3cc
$func21497	@	60ef477….wasm:0x34cb18
$func21461	@	60ef477….wasm:0x34c54a
$func21462	@	60ef477….wasm:0x34c553
$func11361	@	60ef477….wasm:0x274177
$func11362	@	60ef477….wasm:0x2741d4
$func11364	@	60ef477….wasm:0x2742b6
$func11368	@	60ef477….wasm:0x274450
$func12000	@	60ef477….wasm:0x286420
$func3374	@	60ef477….wasm:0x1c6288
$func6898	@	60ef477….wasm:0x209dc3
$func21319	@	60ef477….wasm:0x3495cd
$func21320	@	60ef477….wasm:0x3495d7
$func21345	@	60ef477….wasm:0x349c5b
$func21327	@	60ef477….wasm:0x34974a
$func21325	@	60ef477….wasm:0x3496bf
$func21326	@	60ef477….wasm:0x3496ed
$func3390	@	60ef477….wasm:0x1c6671
$func3374	@	60ef477….wasm:0x1c6288
$func6898	@	60ef477….wasm:0x209dc3
$func7125	@	60ef477….wasm:0x20d863
$func7235	@	60ef477….wasm:0x20e86a
$func7236	@	60ef477….wasm:0x20e872
$__callFunction____->Unit_	@	60ef477….wasm:0x1c3837
(anonymous)	@	client-app.uninstantiated.mjs:106
Promise.then		
(anonymous)	@	client-app.uninstantiated.mjs:137
kotlinx.coroutines.__callJsClosure_(()->Unit)	@	client-app.uninstantiated.mjs:138
$func7247	@	60ef477….wasm:0x20e9b1
v
Try navigating to an empty screen, see if that works. Most likely something is crashing on the screen you're trying to navigate to.
Try adding logs into various places around where you're calling the navigation action. You might be able to pinpoint the culprit via logs instead of this stack trace.