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.

react-event-listener incompatibility >=0.5.6

See original GitHub issue
  • This is a v1.x issue (v0.x is no longer maintained).
  • I have searched the issues of this repository and believe that this is not a duplicate.

Expected Behavior

Install @material-ui/core 1.0.0 from npm it pulls in react-event-listener 0.5.8 as per dependency of ^0.5.1.

Create a tooltip as so, tooltip should render…

<Tooltip title="title">
  <span>Content</span>
</Tooltip>

Current Behavior

Throws an error.

Warning: React.createElement: type is invalid -- expected a string (for built-in component) or a class/function (for composite components) but got: object.
  Check the render method of `Tooltip`.
  ...

A little more digging reveals that the import of react-event-listener comes back with a nested default

{
  default: {
    default: function () { ... }
  }
}

Forcing an install of react-event-listener 0.5.5 doesn’t display this issue. The import comes in as expected

Your Environment

Tech Version
Material-UI v1.0.0
React v16.3.2
browser Chrome 66

Issue Analytics

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

github_iconTop GitHub Comments

1reaction
TrySoundcommented, May 23, 2018

Just remove that line for 0.5.9.

Read more comments on GitHub >

github_iconTop Results From Across the Web

react-event-listener incompatibility >=0.5.6 #11550 - GitHub
This is a v1.x issue (v0.x is no longer maintained). I have searched the issues of this repository and believe that this is...
Read more >
Handling Events - React
React events are named using camelCase, rather than lowercase. With JSX you pass a function as the event handler, rather than a string....
Read more >
Changelog - ReactPHP
The Loop::get() method can be used to get the currently active event loop instance. // deprecated $loop = React\EventLoop\Factory::create(); ...
Read more >
React (JavaScript library) - Wikipedia
React is a free and open-source front-end JavaScript library for building user interfaces ... or an "eventListener" set on the "document" because of...
Read more >
Changelog - Cypress Documentation
Fixed an edge-case bug where Cypress would hang in run-mode if an error was thrown from a test:before:run event handler. Fixes #23039. Fixes...
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