Skip to content

Conversation

silvenon
Copy link

When you're compiling tests with webpack for Node (target: node), isomorphic-fetch will use node-fetch, which uses encoding, which requires iconv dynamically, which causes warnings. This config will cause those requires to throw an error.

It can seem weird to compile tests with webpack for Node, but it makes sense when you want to run your tests in the command-line or when you want to use certain Node testing tools or when you're testing React code which will be rendering on the server…

Of course, I won't be very sad if you don't feel like merging this, people with similar issues still will be able to find this PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant