maps_adapter_google_maps 0.2.0

  • Readme
  • Changelog
  • Installing
  • new59

Pub Package Github Actions CI

Overview #

This is a Google Maps Android/iOS SDK adapter for the package maps.

Getting started #

1.Add dependency #

In pubspec.yaml, you should have:

dependencies:
  maps_adapter_google_maps: ^0.2.0

2.Modify configuration files #

For Android support, you need to modify android/app/src/main/AndroidManifest.xml.

For iOS support, you need to modify:

  • ios/Runner/AppDelegate.m (if your Flutter project uses Objective-C)
  • ios/Runner/AppDelegate.swift (if your Flutter project uses Switf)

You also need to ensure that ios/Runner/Info.plist has something like:

	<key>io.flutter.embedded_views_preview</key>
	<true/>
	<key>Privacy - Location When In Use Usage Description</key>
	<string>A description of your privacy policy.</string>

3.Set map adapter #

In your main function:

import 'package:maps/maps.dart';
import 'package:maps_adapter_google_maps';

void main() {
  MapAdapter.defaultInstance = const GoogleMapsNativeAdapter();

  // ...
}

Contributing? #

Test changes manually with the example application in the repository.

0.2.0 #

  • Migrates to 'maps' 0.3.

0.1.0 #

  • Initial release.

Use this package as a library

1. Depend on it

Add this to your package's pubspec.yaml file:


dependencies:
  maps_adapter_google_maps: ^0.2.0

2. Install it

You can install packages from the command line:

with Flutter:


$ flutter pub get

Alternatively, your editor might support flutter pub get. Check the docs for your editor to learn more.

3. Import it

Now in your Dart code, you can use:


import 'package:maps_adapter_google_maps/maps_adapter_google_maps.dart';
  
Popularity:
Describes how popular the package is relative to other packages. [more]
23
Health:
Code health derived from static analysis. [more]
100
Maintenance:
Reflects how tidy and up-to-date the package is. [more]
90
Overall:
Weighted score of the above. [more]
59
Learn more about scoring.

We analyzed this package on Jul 9, 2020, and provided a score, details, and suggestions below. Analysis was completed with status completed using:

  • Dart: 2.8.4
  • pana: 0.13.14
  • Flutter: 1.17.5

Analysis suggestions

Package does not support Flutter platform android

Because:

  • package:maps_adapter_google_maps/maps_adapter_google_maps.dart that imports:
  • package:maps_adapter_google_maps/src/google_maps.dart that imports:
  • package:maps_adapter_google_maps/src/google_maps_impl_default.dart that imports:
  • package:maps/maps.dart that imports:
  • package:maps/src/adapters/apple_maps.dart that imports:
  • package:maps/src/adapters/apple_maps_impl_default.dart that imports:
  • package:apple_maps_flutter/apple_maps_flutter.dart that declares support for platforms: ios

Package does not support Flutter platform linux

Because:

  • package:maps_adapter_google_maps/maps_adapter_google_maps.dart that imports:
  • package:maps_adapter_google_maps/src/google_maps.dart that imports:
  • package:maps_adapter_google_maps/src/google_maps_impl_default.dart that imports:
  • package:maps/maps.dart that imports:
  • package:maps/src/adapters/google_maps.dart that imports:
  • package:maps/src/adapters/google_maps_impl_default.dart that imports:
  • package:web_browser/web_browser.dart that imports:
  • package:web_browser/src/web_browser.dart that imports:
  • package:webview_flutter/webview_flutter.dart that declares support for platforms: android, ios

Package does not support Flutter platform macos

Because:

  • package:maps_adapter_google_maps/maps_adapter_google_maps.dart that imports:
  • package:maps_adapter_google_maps/src/google_maps.dart that imports:
  • package:maps_adapter_google_maps/src/google_maps_impl_default.dart that imports:
  • package:maps/maps.dart that imports:
  • package:maps/src/adapters/google_maps.dart that imports:
  • package:maps/src/adapters/google_maps_impl_default.dart that imports:
  • package:web_browser/web_browser.dart that imports:
  • package:web_browser/src/web_browser.dart that imports:
  • package:webview_flutter/webview_flutter.dart that declares support for platforms: android, ios

Package does not support Flutter platform web

Because:

  • package:maps_adapter_google_maps/maps_adapter_google_maps.dart that imports:
  • package:maps_adapter_google_maps/src/google_maps.dart that imports:
  • package:maps_adapter_google_maps/src/google_maps_impl_browser.dart that imports:
  • package:maps/maps.dart that imports:
  • package:maps/src/adapters/google_maps.dart that imports:
  • package:maps/src/adapters/google_maps_impl_browser.dart that imports:
  • package:web_browser/web_browser.dart that imports:
  • package:web_browser/src/web_browser.dart that imports:
  • package:webview_flutter/webview_flutter.dart that declares support for platforms: android, ios

Package does not support Flutter platform windows

Because:

  • package:maps_adapter_google_maps/maps_adapter_google_maps.dart that imports:
  • package:maps_adapter_google_maps/src/google_maps.dart that imports:
  • package:maps_adapter_google_maps/src/google_maps_impl_default.dart that imports:
  • package:maps/maps.dart that imports:
  • package:maps/src/map_launcher.dart that imports:
  • package:maps/src/map_launcher_impl_default.dart that imports:
  • package:url_launcher/url_launcher.dart that declares support for platforms: android, ios, linux, macos, web

Package not compatible with SDK dart

Because:

  • maps_adapter_google_maps that is a package requiring null.

Health suggestions

Fix lib/src/google_maps_impl_default.dart. (-0.50 points)

Analysis of lib/src/google_maps_impl_default.dart reported 1 hint:

line 35 col 9: The value of the local variable 'implMarkers' isn't used.

Maintenance suggestions

Maintain an example. (-10 points)

Create a short demo in the example/ directory to show how to use this package.

Common filename patterns include main.dart, example.dart, and maps_adapter_google_maps.dart. Packages with multiple examples should provide example/README.md.

For more information see the pub package layout conventions.

Dependencies

Package Constraint Resolved Available
Direct dependencies
Dart SDK >=2.7.0 <3.0.0
flutter 0.0.0
google_maps_flutter ^0.5.0 0.5.28+1
maps ^0.3.0 0.3.0
Transitive dependencies
apple_maps_flutter 0.1.1+1
async 2.4.2
built_collection 4.3.2
built_value 7.1.0
charcode 1.1.3
collection 1.14.12 1.14.13
convert 2.1.1
crypto 2.1.5
cryptography 1.4.1
cryptography_flutter 1.0.0
csslib 0.16.1
cupertino_icons 0.1.3
database 0.3.3
fixnum 0.10.11
flutter_plugin_android_lifecycle 1.0.8
flutter_web_plugins 0.0.0
google_maps_flutter_platform_interface 1.0.2
html 0.14.0+3
js 0.6.2
matcher 0.12.8
meta 1.1.8 1.2.1
path 1.7.0
platform_detect 1.4.0
plugin_platform_interface 1.0.2
protobuf 1.0.1
pub_semver 1.4.4
quiver 2.1.3
share 0.6.4+3
sky_engine 0.0.99
source_span 1.7.0
stack_trace 1.9.5
stream_transform 1.2.0
term_glyph 1.1.0
typed_data 1.1.6 1.2.0
universal_html 1.2.3
universal_io 1.0.1
url_launcher 5.5.0
url_launcher_linux 0.0.1+1
url_launcher_macos 0.0.1+7
url_launcher_platform_interface 1.0.7
url_launcher_web 0.1.2
vector_math 2.0.8 2.1.0-nullsafety
web_browser 0.2.2
webview_flutter 0.3.22+1
zone_local 0.1.2
Dev dependencies
flutter_test
pedantic ^1.9.0