Git and Node.js are required to run this sample locally. Follow these instructions to install Node.js and NPM. The following commands clone, install dependencies and start the sample application.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-04-14 UTC."],[[["This example showcases creating a basic Google Map using HTML and the `gmp-map` web component."],["The map is initialized using JavaScript (or TypeScript) with an `initMap` function."],["Sample code provides implementation in both JavaScript and TypeScript, along with the corresponding HTML and CSS."],["Users can experiment with the example via provided links to JSFiddle and Google Cloud Shell or clone the repository for local execution."]]],["This example demonstrates how to create a map using HTML and the `gmp-map` element. The HTML uses a `\u003cgmp-map\u003e` tag with attributes like `center`, `zoom`, and `map-id`. It loads the Maps JavaScript API via a `\u003cscript\u003e` tag. TypeScript and JavaScript code initialize the map, logging a confirmation. CSS styles the map. The sample can be tried online via JSFiddle or Google Cloud Shell, and can be cloned locally by cloning a git repository, installing dependencies, and starting the app.\n"]]