tomchentw / react-google-maps

React.js Google Maps integration component
https://tomchentw.github.io/react-google-maps/
MIT License
4.62k stars 939 forks source link

Google Maps Library Errors #1010

Closed AliYmn closed 4 years ago

AliYmn commented 4 years ago

Hi, i think my code is correct based on documents(react google maps) but i get some error. I don't think these mistakes are about me.

my code here : https://gist.github.com/AliYmn/597193b7f3d060787c3695a3bbaa85de

  1. Type Error : Cannot read property 'zoom' of null https://sentry.io/share/issue/c3b96e07aa02442ca7cfc82c6bacec99/
  2. Type Error : null is not an object (evaluating 'l.g.g.g.zoom') https://sentry.io/share/issue/b958a0b4746c4544be3dba35d1d57e4c/
  3. Type Error : geometry.location ( this does not appear on my code) https://sentry.io/share/issue/7cb655e188da40919571206f6fefef81/

I give details my error. I can't fix to them , can you help me ? Thank you...

JustFly1984 commented 4 years ago

@AliYmn The repo of this project is unmaintained more than a year, and we had build new version https://www.npmjs.com/package/@react-google-maps/api

We had rewrite it to TypeScript, and updating it frequently: https://github.com/JustFly1984/react-google-maps-api/tree/master/packages/react-google-maps-api You can enjoy autocomplete.

You can see our docs: https://react-google-maps-api-docs.netlify.com/

Also a lot of examples: https://react-google-maps-api-gatsby-demo.netlify.com/ https://github.com/JustFly1984/react-google-maps-api/tree/master/packages/react-google-maps-api-gatsby-example/src/examples

The bundle size is much smaller: https://bundlephobia.com/result?p=@react-google-maps/api@1.7.5

Enjoy!

AliYmn commented 4 years ago

Thank you for answer.