-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
6e5df19
commit 79ab617
Showing
3 changed files
with
30 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
29 changes: 29 additions & 0 deletions
29
...StadiaMapsAutocompleteSearch/Documentation.docc/StadiaMapsAutocompleteSearch.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
# ``StadiaMapsAutocompleteSearch`` | ||
|
||
|
||
## Overview | ||
|
||
This package helps you easily add geographic autocomplete search to a SwiftUI app. | ||
It supports most use cases out of the box, and is easily extensible to create a tailored design. | ||
|
||
* Displays a search box and list which you can embed in other views | ||
* Provides a callback handler with the result details when users tap a result | ||
* Can bias search results to be nearby a specific location | ||
* Automatically localizes place names based on the user's device settings (where available) | ||
|
||
![Screenshot](screenshot) | ||
|
||
## Quickstart | ||
|
||
First, you'll need a Stadia Maps API key. | ||
Create one for free [here](https://client.stadiamaps.com/signup/?utm_source=spm&utm_campaign=sdk_readme&utm_content=swiftui_autocomplete_landing). | ||
|
||
Then, add it to your SwiftUI view like this: | ||
|
||
```swift | ||
AutocompleteSearch(apiKey: previewApiKey, onResultSelected: { selection in | ||
// TODO: Selection logic | ||
}) | ||
``` | ||
|
||
Refer to the ``AutocompleteSearch`` documentation for more details on customization. |
File renamed without changes