googlemaps / googlemaps/flutter-navigation-sdk

[Bug]: Package does not support Web and causes duplicate class errors with google_maps_flutter

Open
#498 8 comments 0 reactions 1 assignee Claimed by @jokerttu View on GitHub
status: investigating type: bug
Dominant language
Dart
Stars
75
Forks
54
Avg merge
4d 2h
Merged PRs (30d)
5

Description

### Is there an existing issue for this?

- [x] I have searched the existing issues

### Description of the bug

There are numerous issues about the duplicate class build errors when this package is used alongside `google_maps_flutter` (#129, #244, #247, #250).

However, the big problem is that this package is not compatible with Web platforms. This is partially understandable, since navigation will not work on the web - but the solution to many of these issues is that this package has a built in `GoogleMapsMapView` and to remove the `google_maps_flutter` dependency.

For a cross platform app, I want to use maps AND navigation on mobile platforms. On web, I still want to show maps only. Using `google_navigation_flutter` for mobile and `google_maps_flutter` for web does not work due to the build errors, and using `google_navigation_flutter` for all platforms doesn't work because it doesn't support web.

If these build issues cannot be fixed, can this package support `GoogleMapsMapView` on Web (or even better all) platforms?

### Flutter version

3.35.6

### Package version

0.6.5

### Native SDK versions

- [x] I haven't changed the version of the native SDKs

### Flutter Doctor Output

Doctor summary (to see all details, run flutter doctor -v):
[√] Flutter (Channel stable, 3.35.6, on Microsoft Windows [Version 10.0.26100.6584], locale en-US)
[√] Windows Version (Windows 11 or higher, 24H2, 2009)
[!] Android toolchain - develop for Android devices (Android SDK version 36.0.0)
! Some Android licenses not accepted. To resolve this, run: flutter doctor --android-licenses
[√] Chrome - develop for the web
[X] Visual Studio - develop Windows apps
X Visual Studio not installed; this is necessary to develop Windows apps.
Download at https://visualstudio.microsoft.com/downloads/.
Please install the "Desktop development with C++" workload, including all of its default components
[√] Android Studio (version 2025.1.4)
[√] VS Code (version 1.105.0)
[√] Connected device (4 available)
[√] Network resources

! Doctor found issues in 2 categories.

### Steps to reproduce

1. Add `google_navigation_flutter` to your project.
2. Run on web.

### Expected vs Actual Behavior

Package should work with web and allow maps to be shown without navigation.

### Code Sample

```dart
// Example code here
```

### Additional Context

_No response_

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.