Skip to content

googlemaps-samples/js-api-samples

Repository files navigation

js-api-samples

Description

Welcome to the js-api-samples repository, the home of Google Maps JavaScript API documentation samples.

Important Note: Repository Migration in Progress

This repository (js-api-samples) is the new home for the Maps JavaScript API samples.

We are currently migrating all samples from the old repository (js-samples). During this transition, you may find some samples are still missing or under development.

We appreciate your patience as we complete this migration. Please check back regularly for updates.

Try the examples out at Google Maps JavaScript API documentation.

Development

Each example is one atomic unit, for which dependencies must be individually set up.

Build samples

  1. Run npm i to install dependencies. You only need to do this once, and thereafter only to update dependencies.
  2. Navigate to the top level (samples/).
  • To build a single sample, run npm run build --workspace=sample-name/
  • To build all samples, run npm run build-all.

Build output is copied to the main dist/ folder. Each individual sample folder also contains a dist/ folder, but this is only used by Vite for live preview.

Run a single sample

  1. Navigate to the folder for the sample you want to run (cd samples/sample-name).
  2. Run npm start to start a server with that sample.

Testing

  • To test, navigate to project root and run npx playwright test. {# TODO: Expand this section. #}

Contributing

Contributions are welcome! Please see contributing for more information.

Terms of Service

This library uses Google Maps Platform services. Use of Google Maps Platform services through this library is subject to the Google Maps Platform Terms of Service.

This library is not a Google Maps Platform Core Service. Therefore, the Google Maps Platform Terms of Service (e.g. Technical Support Services, Service Level Agreements, and Deprecation Policy) do not apply to the code in this library.

Support

This library is offered via an open source license. It is not governed by the Google Maps Platform Support Technical Support Services Guidelines, the SLA, or the Deprecation Policy (however, any Google Maps Platform services used by the library remain subject to the Google Maps Platform Terms of Service).

This library adheres to semantic versioning to indicate when backwards-incompatible changes are introduced. Accordingly, while the library is in version 0.x, backwards-incompatible changes may be introduced at any time.

If you find a bug, or have a feature request, please file an issue on GitHub. If you would like to get answers to technical questions from other Google Maps Platform developers, ask through one of our developer community channels. If you'd like to contribute, please check the Contributing guide.

You can also discuss this library on our Discord server.

About

The home of Google Maps JavaScript API documentation samples.

Resources

License

Code of conduct

Stars

Watchers

Forks

Packages

No packages published

Contributors 3

  •  
  •  
  •