flutter_map icon indicating copy to clipboard operation
flutter_map copied to clipboard

chore(example): added WASM support to example

Open JaffaKetchup opened this issue 1 year ago • 5 comments

Supersedes #1867 by @josxha.

  • Reset web index.html config file to initial state in Flutter 3.22
  • Also adds required headers to Firebase config (hopefully)

Would like to add an indicator using dart-lang/sdk/issues/55694 when it becomes available, to confirm usage of WASM.

JaffaKetchup avatar May 16 '24 19:05 JaffaKetchup

Also adds required headers to Firebase config (hopefully)

It's possible to deploy branches temporarily on firebase hosting, see https://github.com/FirebaseExtended/action-hosting-deploy?tab=readme-ov-file#channelid-string. Maybe a good way to test those changes or even to setup a permanent hosted version running on wasm?

josxha avatar May 16 '24 19:05 josxha

It's possible to deploy branches temporarily on firebase hosting, see FirebaseExtended/action-hosting-deploy#channelid-string.

Yep, I've looked into this extensively before. However, I disabled it, as most of our PRs come from forks, and for security reasons, GitHub Actions and Firebase won't do this from a fork PR. I can try deploying a preview version manually perhaps?

JaffaKetchup avatar May 16 '24 19:05 JaffaKetchup

https://fleaflet-firebase--preview-wasm-bfczu5tt.web.app/

Can confirm it doesn't work, but only because the CTP uses Dio which doesn't support Dio yet. Not sure why I couldn't reproduce this locally, but I guess we'll have to hold off for now.

JaffaKetchup avatar May 16 '24 19:05 JaffaKetchup

Open pull request here:

  • https://github.com/cfug/dio/pull/2215

While I tested my branch I had the problem that the polygon stresstest page gets stuck and doesn't seem to unfreezed after i zoomed in. Does this happen here too?

josxha avatar May 16 '24 20:05 josxha

Waiting for:

  • https://github.com/cfug/dio/pull/2215
  • A Flutter release (beta channel) with Dart 3.5.0-185.0.dev, to include https://github.com/dart-lang/sdk/commit/6b71aa1f3e997fcbbb19930a1c029ffcebf33d67

JaffaKetchup avatar May 26 '24 21:05 JaffaKetchup

Since web_adapter v2.0.0, dio shouldn't be a blocker anymore. Dart 3.5 is out as of Flutter 3.24.

lishaduck avatar Sep 06 '24 16:09 lishaduck

Wasm is now available! See it working in the preview (confirm with the drawer): https://fleaflet-firebase--wasm-test-g7fo47s3.web.app/.

JaffaKetchup avatar Sep 12 '24 18:09 JaffaKetchup