Skip to content

Commit

Permalink
Update ModuleNotFoundPlugin to support Webpack 5 (facebook#10205)
Browse files Browse the repository at this point in the history
  • Loading branch information
raix authored and sumanthratna committed Aug 4, 2021
1 parent 816e9f6 commit 8f47fec
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion packages/react-dev-utils/ModuleNotFoundPlugin.js
Original file line number Diff line number Diff line change
Expand Up @@ -100,8 +100,13 @@ class ModuleNotFoundPlugin {
const { prettierError } = this;
compiler.hooks.make.intercept({
register(tap) {
// "SingleEntryPlugin" can be removed when Webpack 4 no longer have to be supported
if (
!(tap.name === 'MultiEntryPlugin' || tap.name === 'SingleEntryPlugin')
!(
tap.name === 'MultiEntryPlugin' ||
tap.name === 'SingleEntryPlugin' ||
tap.name === 'EntryPlugin'
)
) {
return tap;
}
Expand Down

0 comments on commit 8f47fec

Please sign in to comment.