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.

1.1.1 error __webpack_require___(...) is not a function

See original GitHub issue

Hi there!

When using react-relay v.1.5.0, the following error is given.

screenshot 2018-04-02 14 11 20

The error points to this line:

https://github.com/facebook/relay/blob/256b7a77e9f8b9d360282580c9a316c5f079ee13/packages/react-relay/modern/ReactRelayQueryRenderer.js#L313

It seems like the import line 19 no longer works.

const polyfill = require('react-lifecycles-compat');

When I install react-lifecycles-compat v.1.1.0 to project, then the error disappears.

Thoughts?

Issue Analytics

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

github_iconTop GitHub Comments

1reaction
bvaughncommented, Apr 3, 2018

Release 1.1.1 has been deprecated (so it will log a warning if it’s added) and 1.1.2 has been released without ES modules. That should be sufficient to close this issue.

I’ll move the remainder of the work (discussion about breaking changes) to a new issue.

1reaction
bvaughncommented, Apr 2, 2018

Hm. This is unexpected. Can you share a repro?

Prior to (and after) releasing, I tested the 1.1.1 release with create-react-app and Code Sandbox and it worked okay.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Webpack, require is not a function - node.js - Stack Overflow
It's a static server which will automatically recompile your files using the same webpack config so you can be sure the code you're...
Read more >
TypeError: require is not a function · Issue #479 - GitHub
Hello, I had a working ng2-handsontable on production but with a latest deploy, I'm getting a type error at (handsontable.js:46).
Read more >
TypeError: require(...) is not a function in Node.js | bobbyhadz
To solve the "TypeError: require(...) is not a function", make sure to place a semicolon between your require call and an immediately invoked...
Read more >
[webpack-cli] referenceerror: require is not defined in es ...
I'd either try removing the "module" declaration from the package.json, and stick to CommonJS in webpack, or use import/export clauses in webpack and...
Read more >
webpack-stats-plugin - npm
Webpack stats plugin. Latest version: 1.1.1, last published: 2 months ago. Start using webpack-stats-plugin in your project by running `npm ...
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