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: fast refresh stops on needed bail outs #11105

Merged
merged 2 commits into from
Jul 14, 2021
Merged

fix: fast refresh stops on needed bail outs #11105

merged 2 commits into from
Jul 14, 2021

Commits on Jun 15, 2021

  1. fix: fast refresh stops on needed bail outs

    Fast Refresh requires the HMR runtime to support bail out behaviour (we do not do so within the core runtime as it has to be platform agnostic) - and currently webpackHotDevClient does not do so properly as it circumvents the logic for forced reloads completely when using Fast Refresh.
    
    The changes done here ensures that:
    - If Fast Refresh is not enabled, we would always bail out to a forced reload;
    - If Fast Refresh is enabled and there are updated modules, it indicates the update has at least partially executed, and we can rely on Fast Refresh being resilient to errors and skip the forced reload;
    - If Fast Refresh is enabled and there are none updated modules, it indicates the update cannot be executed without being inconsistent (i.e. Fast Refresh bailed out), we would bail out to a forced reload.
    pmmmwh authored Jun 15, 2021
    Configuration menu
    Copy the full SHA
    33309cf View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    1156f1e View commit details
    Browse the repository at this point in the history