Giter Club home page Giter Club logo

google-map-react-examples's Introduction

Examples for google-map-react library · Build Status

This project was bootstrapped with Create React App.

Stack

Examples

Getting started

Installation

Although I prefer yarn, you can use either yarn or npm:

  • npm install or simply yarn

Run development

  • npm start or yarn start

Runs the app in development mode.
Open http://localhost:3000 to view it in the browser.

The page will automatically reload if you make changes to the code.
You will see the build errors and lint warnings in the console.

Run production build

  • npm run build or yarn build

Builds the app for production to the build folder.
It correctly bundles React in production mode and optimizes the build for the best performance.

The build is minified and the filenames include the hashes.
By default, it also includes a service worker so that your app loads from local cache on future visits.

Your app is ready to be deployed.

Deploy to GH pages

  • npm run deploy or yarn deploy

This will push a branch named gh-pages to the repository, which will be used by GH to render the latest version of our site.

google-map-react-examples's People

Contributors

barakplasma avatar byeokim avatar dependabot[bot] avatar itsmichaeldiego avatar mt-deva avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

google-map-react-examples's Issues

Heatmap issue, 'h[m.x] is undefined'

Hello,

Putting together an app as part of a final school project.
I'm on the last part of it, and have been following the documentation for the correct syntax. The map itself will load properly, as well as the markers, but when attempting to load the heatmap layer, it breaks the app and returns an error that says: 'h[m.x] is undefined'. Here is the component
<GoogleMapReact defaultZoom={8} defaultCenter={{ lat: diffStateCoords[0].lat, lng: diffStateCoords[0].lng }} heatmapLibrary={true} heatmap={diffStateHeatMapData} bootstrapURLKeys={{ key: 'my-key-goes-here', libraries: ['visualization'] }} yesIWantToUseGoogleMapApiInternals > {diffStateCombinedData.map(county => ( <Marker key={county.name} lat={county.coordinates[1]} lng={county.coordinates[0]} text={county.county} countyName={county.name} state={county} percentVaxxed={county.percentVaxxed} /> ))} </GoogleMapReact>

The object for the diffStateHeatMapData looks like:
{positions: diffStateMapData,
options: {
radius: 90,
opacity: .5
}}

The positions for diffStateMapData are in an array, where each object has lat, lng, and weight properties.

Not really sure what I'm doing wrong here. Have tried what feels like everything, so I'm hoping y'all can shed some light on the issue. Thanks so much!

getBounds()

Hello.

Is there any way to call the map.getBounds() function? I need to reset the bounds of a nearbySearch upon manually re-centering and can't seem to figure out how to do so.

Cheers,
Dave

Loading librairies in a correct way

Thank you for the examples they are very helpful to explain how to use the library.
I tried the examples, in the main page when I click on Default Element it works. The Map with markers is shown.

When I click on SearchBox Element in the main page, I get TypeError: mapApi.places is undefined.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.