Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix HMR/Live Reloading when running against webpack v5 and have an array of targets when using webpack-dev-server v3 #3271

Open
wants to merge 1 commit into
base: v3
Choose a base branch
from

Conversation

greyepoxy
Copy link

  • This is a bugfix
  • This is a feature
  • This is a code refactor
  • This is a test update
  • This is a docs update
  • This is a metadata update

For Bugs and Features; did you add new tests?

Updated the existing addEntries web targets test

Motivation / Use-Case

Since v4 is not out yet (where this issue is fixed) this fixes the live reload issue #2758 that occurs when a user is using webpack v5.

Breaking Changes

None

Additional Info

Tested against the examples and my own private webpack v5 config to confirm that it detected that the config was a web config.

Looking at the fix in the v4 branch I suspect this will not work as well as that change. Specifically if someone uses the new browserlists target option this change won't detect that as a web config. Since this change only needs to hold people over until v4 is released I believe its okay since in the example above the user could just add web to their target array.

@codecov
Copy link

codecov bot commented May 11, 2021

Codecov Report

❗ No coverage uploaded for pull request base (v3@5cb545f). Click here to learn what that means.
The diff coverage is n/a.

Impacted file tree graph

@@          Coverage Diff          @@
##             v3    #3271   +/-   ##
=====================================
  Coverage      ?   93.49%           
=====================================
  Files         ?       34           
  Lines         ?     1337           
  Branches      ?      384           
=====================================
  Hits          ?     1250           
  Misses        ?       85           
  Partials      ?        2           

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 5cb545f...d9d1293. Read the comment docs.

@snitin315
Copy link
Member

You can use v4.0.0-beta.3, Just a couple of more PRs and we will do a stable release in the near future.

@greyepoxy
Copy link
Author

Yes I am aware this is fixed in v4 but due to that version still being in beta my company will not update (Tableau) due to the risk of issue. I was hoping to send this request a few weeks ago but only got permission to make the commit recently.

@alexander-akait
Copy link
Member

Make sense as patch release, I will try to do release in near future

lupko added a commit to lupko/gooddata-ui-sdk that referenced this pull request May 21, 2021
-  Due to bug in webpack dev server. See webpack/webpack-dev-server#3271

JIRA: RAIL-3383
lupko added a commit to lupko/gooddata-ui-sdk that referenced this pull request May 21, 2021
-  Due to bug in webpack dev server. See webpack/webpack-dev-server#3271

JIRA: RAIL-3383
@greyepoxy
Copy link
Author

greyepoxy commented Jun 8, 2021

@alexander-akait just checking that you are not waiting on me for something, thank you

@alexander-akait
Copy link
Member

Yep, I am here, I am working on rc release for v4, after this I will backport some fixes to v3 too

@bartvandenende-wm
Copy link

it would be great indeed to see this change backported to 3.x for compatibility

@getsetgopi
Copy link

Since my company still supports IE11. It fails when I use target: ["web", "es5"]. I waiting for the fix where live reload and this works together.

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.

None yet

5 participants