mirror of
https://github.com/kingomarnajjar/flex-template-web.git
synced 2026-07-26 06:47:17 +10:00
Run Prettier for docs
This commit is contained in:
parent
5606d8c457
commit
c124bcd732
2 changed files with 21 additions and 10 deletions
|
|
@ -1,12 +1,14 @@
|
|||
# Google Maps
|
||||
|
||||
Flex Template for Web (FTW) offers out of the box support for Google Maps API for showing a map and searching locations
|
||||
with search autocompletion. This document describes how to set up the API key for the API requests
|
||||
to work properly.
|
||||
Flex Template for Web (FTW) offers out of the box support for Google Maps API for showing a map and
|
||||
searching locations with search autocompletion. This document describes how to set up the API key
|
||||
for the API requests to work properly.
|
||||
|
||||
> Note: before making the change to Google Maps, you should consider if you are OK with their current
|
||||
> pricing. There's a pricing calculator available in their
|
||||
> [pricing page](https://cloud.google.com/maps-platform/pricing/). FTW's default map provider is Mapbox, which is often cheaper. [Learn more about how to use Mapbox or some other map provider instead of Google Maps](https://github.com/sharetribe/flex-template-web/blob/e6034c7690c095553f44092b032689cd6b6f7546/docs/map-providers.md).
|
||||
> Note: before making the change to Google Maps, you should consider if you are OK with their
|
||||
> current pricing. There's a pricing calculator available in their
|
||||
> [pricing page](https://cloud.google.com/maps-platform/pricing/). FTW's default map provider is
|
||||
> Mapbox, which is often cheaper.
|
||||
> [Learn more about how to use Mapbox or some other map provider instead of Google Maps](https://github.com/sharetribe/flex-template-web/blob/e6034c7690c095553f44092b032689cd6b6f7546/docs/map-providers.md).
|
||||
|
||||
## Generate a Google Maps API key
|
||||
|
||||
|
|
@ -53,7 +55,8 @@ whether to use the current location from [config.js](../src/config.js). Search f
|
|||
|
||||
## Change components: use Google Map versions instead of Mapbox
|
||||
|
||||
If you wish to use Google Maps instead of Mapbox, you need to make some changes to FTW default setup.
|
||||
If you wish to use Google Maps instead of Mapbox, you need to make some changes to FTW default
|
||||
setup.
|
||||
|
||||
### 1. Include Google Map script instead of Mapbox scripts
|
||||
|
||||
|
|
|
|||
|
|
@ -1,6 +1,11 @@
|
|||
# Integrating to map providers
|
||||
|
||||
Choice of map provider can significantly impact your costs. Flex Template for Web (FTW) originally supported only [Google Maps](./google-maps.md) out of the box, but after Google increased the pricing of its APIs a lot, the default provider was changed to Mapbox. The template now supports both Mapbox and Google Maps, and the map library used by Mapbox is used also by several other map providers, so integrating new providers that support this is rather easy (see instructions at the end of this doc).
|
||||
Choice of map provider can significantly impact your costs. Flex Template for Web (FTW) originally
|
||||
supported only [Google Maps](./google-maps.md) out of the box, but after Google increased the
|
||||
pricing of its APIs a lot, the default provider was changed to Mapbox. The template now supports
|
||||
both Mapbox and Google Maps, and the map library used by Mapbox is used also by several other map
|
||||
providers, so integrating new providers that support this is rather easy (see instructions at the
|
||||
end of this doc).
|
||||
|
||||
## Setting up the Mapbox integration (the default map provider)
|
||||
|
||||
|
|
@ -58,5 +63,8 @@ It is possible to use Google Map instead of the default map provider. Read more
|
|||
|
||||
### How to use other map providers
|
||||
|
||||
The default map setup of FTW uses library called `mapbox-gl-js`. It is supported by quite many other map
|
||||
providers too. Thus, if you wish to use a map provider other than Google Maps or Mapbox, first check if the map provider you are considering is supporting this library. If they are, the change might be quite easy. Note: if you change the map tile provider you should also change geocoding API too (i.e. the API endpoint for `LocationAutocompleteInput` component).
|
||||
The default map setup of FTW uses library called `mapbox-gl-js`. It is supported by quite many other
|
||||
map providers too. Thus, if you wish to use a map provider other than Google Maps or Mapbox, first
|
||||
check if the map provider you are considering is supporting this library. If they are, the change
|
||||
might be quite easy. Note: if you change the map tile provider you should also change geocoding API
|
||||
too (i.e. the API endpoint for `LocationAutocompleteInput` component).
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue