The reference application for the HERE SDK for Flutter (Navigate Edition) shows how a complex and release-ready project targeting iOS and Android devices may look like. You can use it as a source of inspiration for your own HERE SDK based projects - in parts or as a whole.
With this blueprint reference application you can see how UX flows can be built for the HERE SDK - covering the main use cases from searching for POIs, planning and picking a route and finally starting the trip to your destination.
If you are looking for smaller bits & pieces or just want to get started with the integration of the HERE SDK into a simpler project, you may want to start looking into our example apps selection including a stripped down hello_map_app that accompanies the Developer's Guide for the HERE SDK.
The reference application hosted in this repo focuses on how specific features can be implemented and used within the context of a full blown Flutter application - not only to show the usage of our APIs and the HERE SDK functionality as clear and understandable as possible, but also to show how complex Flutter projects in general can be organized and developed with production quality.
The reference application for the HERE SDK for Flutter (Navigate Edition) requires the following prerequisites:
JAVA_HOME
in your env
variables. The minimum supported JDK version is Java 8.On top you need an IDE of your choice. This could be a text editor or IDEs such as Visual Studio Code with the Flutter extension or Android Studio.
Note: If you want to compile, build & run for iOS devices, you also need to have Xcode and CocoaPods installed. If you only target Android devices, Xcode is not required.
Confirm that you meet the overall minimum requirements as listed in the Developer's Guide for the HERE SDK for Flutter (Navigate Edition).
Make sure you have cloned this repository and you have downloaded the HERE SDK for Flutter (Navigate Edition), see above.
Set your HERE SDK credentials: The credentials are read from the environment variables which are set using --dart-define.
flutter run --dart-define=HERESDK_ACCESS_KEY_ID=<YOUR_ACCESS_KEY_ID> --dart-define=HERESDK_ACCESS_KEY_SECRET=<YOUR_ACCESS_KEY_SECRET>
{ "HERESDK_ACCESS_KEY_ID": "
", "HERESDK_ACCESS_KEY_SECRET": " " }
And add additional run args in the IDE: --dart-define-from-file=.env/dev.json
Go to the repository root folder which contains the pubspec.yaml
and run the terminal command flutter pub get
to fetch the required dependencies.
Open the project in your IDE of choice and execute the Flutter project for your target platform.
If you are new to Flutter, here are more detailed steps for you. You may also want to consult the official Flutter site in general and the Flutter SDK documentation in particular first.
flutter build apk --dart-define-from-file=.env/dev.json
or use the command flutter run --dart-define-from-file=.env/dev.json
to build and run on an attached device.pod install
in the ios folder.flutter build ios --dart-define-from-file=.env/dev.json
to build a Runner.app. Type flutter run --dart-define-from-file=.env/dev.json
to build and run on an attached device./repository root/ios/Runner.xcworkspace
project in Xcode and execute and debug from there.Note: You can alternatively also pass the credentails during build by:
flutter build apk --dart-define=HERESDK_ACCESS_KEY_ID=<YOUR_ACCESS_KEY_ID> --dart-define=HERESDK_ACCESS_KEY_SECRET=<YOUR_ACCESS_KEY_SECRET>
You can contribute to this open source project and improve it for others. There are many ways to contribute to this project, whether you want to create an issue, submit bug reports or improve the documentation - we are happy to see your merge requests. Have a look at our contribution guide and code of conduct. Happy coding!
We provide the code 'AS IS'. Using the source code does not come with any additional grant of customer support or promise of specific feature development on our part. If you have any questions, please contact us or check the tag here-api
on stackoverflow.com.
Copyright (C) 2020-2024 HERE Europe B.V.
See the LICENSE file in the root folder of this project for license details.
For other use cases not listed in the license terms, please contact us.
This application and the HERE SDK itself include open source components which require explicit attribution. Please remember to add open source notices in your project. Furthermore, we ask you not to re-sell the icons included in this project.