Flutter_map: [enhancement] Unlocking support Flutter Web

Created on 2 Aug 2019  路  9Comments  路  Source: fleaflet/flutter_map

Considering that this is one of the most viable, flexible and Flutter-y map plugin on Pub starting to work on getting compatibility with the future release of Flutter Web would be great.
There are some blocking dependencies so maybe we could start by listing them (or their sub-dependencies) then contact the maintainers to understand their plans for Flutter Web compatibility.

This issue could be used to track the activities needed and done before implementing anything to achieve Flutter Web support.

I will start on my spare time.

enhancement help wanted

All 9 comments

Ok, from my first analysis it seems that the main blockers are https://github.com/tekartik/sqflite/issues/212 and https://github.com/dart-lang/http/issues/288. I've seen some references to dart:io which from my understanding is not working on Flutter Web which means there are more blocking issues to analyze.

for what it's worth, sqlflite could be removed (since it's only used by the MBTiles plugin)

Also cached_network_image uses sqflite since 0.6.0. Whenever I'm free I'll look if there is a way to inject a different (and web compatible) cache manager while keeping the package. If that is not possible I'll see if advanced_network_image is compatible.

Would need more testing, but we could probably replace Sqflite with https://github.com/leisim/hive which is written in pure Dart

We'd need to swap out cached_network_image to completely get rid of sqflite or create a PR to change their dependency to hive.

Hive seems to be more performant than sqflite which could be a good argument to push the PR.

I'm using this comment also to update the http package blocker to a different issue: https://github.com/flutter/flutter/issues/34858.

edit: grammar

I've been using sqflite via moor https://github.com/simolus3/moor/ on flutter-web for a while now and it seems to work fine.

Specifically, moor uses sqlite.js a WASM sqlite implementation:
https://github.com/simolus3/moor/blob/master/moor/lib/moor_web.dart

Any updates on this?

Now that cached_network_image has basic support for the Web, can we update the version used in this plugin?

I just created a small sample app with flutter_map and tried it in different browser. Surprisingly it worked in Chrome and Firefox.
I tested the general map with some markers, so definitely no deep dive but so far everything worked just fine. :)
Am I missing something here?

Was this page helpful?
0 / 5 - 0 ratings

Related issues

vinicentus picture vinicentus  路  3Comments

zozeei picture zozeei  路  4Comments

EdHubbell picture EdHubbell  路  4Comments

abhijithvijayan picture abhijithvijayan  路  4Comments

aytunch picture aytunch  路  4Comments