question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Uncaught TypeError: Cannot read property 'apply' of undefined

See original GitHub issue

The google.map library triggers this error:

Uncaught TypeError: Cannot read property 'apply' of undefined

when a listener exists in the props object but is undefined.

Maybe we could change this line:

https://github.com/tomchentw/react-google-maps/blob/5748a96ec61cf55f8bccaeb024be6d7737a15773/src/lib/enhanceElement.js#L44

to

if (typeof props[onEventName] === 'function') {

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:7 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
dlapecommented, Sep 19, 2017

The same error with the Map with a SearchBox, and I think there’s something to do with this line const nextCenter = _.get(nextMarkers, '0.position', this.state.center);

1reaction
oshalygincommented, Jul 25, 2017

I’ll be adding tests for this in the near future and we can include this as part of that PR.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Cannot read property 'apply' of undefined · Issue #2359 - GitHub
When I use a regular browser like google chrome everything works as expected, then I used blisk I got an error saying app.js:14868...
Read more >
Redux TypeError: Cannot read property 'apply' of undefined
If you have the devtools disabled however, __REDUX_DEVTOOLS_EXTENSION__ is undefined and becomes the second argument to compose function.
Read more >
Error message "Cannot read property 'apply' of undefined"
When the UI Action is script is executed, this error is shown in the browser console: Uncaught TypeError: Cannot read property 'apply' of...
Read more >
Cannot read property 'apply' of undefined" - Forums - Liferay
In the console, persistent errors : "Uncaught TypeError: Cannot read property 'apply' of undefined" In what may be the reason?
Read more >
Uncaught TypeError: Cannot read property 'apply' of undefined
Uncaught TypeError : Cannot read property 'apply' of undefined · you are on master · you try with safe-mode if possible · give...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found