Hello! MapKit JS sample code is now available at https://maps.developer.apple.com/sample-code.
Here's a list of the samples that are currently available:
- Embedded Map Demonstrates simply displaying a map with minimal code.
- Annotations & Reverse Geocoding Demonstrates adding/removing annotations, using the Reverse Geocoding API to find place data.
- Annotations with a Custom Callout Demonstrates how to add custom styles to annotation callouts.
- US Population By State Overlays Demonstrates displaying, transforming, and interacting with GeoJSON-based map overlays.
- Callout Accessory Views Demonstrates displaying additional customized elements within a callout.
- Region and Zoom Limits Demonstrates limiting a map's viewport's zoom levels and latitude/longitude constraints.
- Animated Polyline Overlays Demonstrates animating an overlay property in a request animation frame loop.