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.

http2 module not found

See original GitHub issue

After updating from superagent@4.1.0 to 5.0.0 in create-react-app with typescript I’m running into an error:

./node_modules/superagent/lib/node/http2wrapper.js
Module not found: Can't resolve 'http2' in '{redacted}\node_modules\superagent\lib\node'

Downgrading back to 4.1.0 solves this problem

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:13

github_iconTop GitHub Comments

1reaction
niftylettucecommented, Mar 28, 2019

@AndreiEnache please try v5.0.2 (just released!) and get back to me - thank you for reporting.

We were missing a line in browser config in package.json that would have instructed webpack (in your case) to require the client-side version ./lib/client.js as opposed to ./lib/node/index.js.

See https://github.com/visionmedia/superagent/commit/ccc7f564f6db79f150f029d850a01452bc07f7e3

0reactions
AndreiEnachecommented, Mar 28, 2019

It’s fixed.

Thank you!

Read more comments on GitHub >

github_iconTop Results From Across the Web

Getting error Module not found: Can't resolve 'http2' in '/ ...
When installing Dialogflow npm module, I am getting this error Module not found: Can't resolve 'http2' in '/node_modules/@grpc/grpc-js/build/src' When I add ...
Read more >
Can't resolve 'http2' when importing firebase-admin - ...
Failed to compile ./node_modules/@grpc/grpc-js/build/src/channel.js Module not found: Can't resolve 'http2' in '/Users ...
Read more >
How to fix 'Module not found: Can't resolve 'http' in ... - YouTube
Basically, just change 'react-scripts' to 4.0.2 in your package.json and run `npm install` again :D Follow me on Twitter: ...
Read more >
Http2 Dependency not found - Help - Fauna Forums
This dependency was not found: http2 in ./node_modules/faunadb/src/_http/http2Adapter.JavaScript. Installing http2 leads to another missing ...
Read more >
Can't resolve 'http2' when importing firebase-admin-Reactjs
[Solved]-Module Not Found: Can't resolve 'http2' when importing firebase-admin-Reactjs ... I have changed to use yarn. Remove yarn remove firebase-admin Install ...
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