Skip to content

Fix incremental webpack mode without live_reload

Lukas Eipert requested to merge leipert-fix-incremental-compiling into master

What does this MR do and why?

Fix incremental webpack mode without live_reload

If live_reload is disabled, we accidentally kill the webpack dev server because devServer.webSocketServer.clients is undefined, because we are checking the wrong condition. This fixes the condition check.

Improve webpack incremental compiler status

Adjust the message depending on the status of LIVE_RELOAD. If the webpack dev server has live reload disabled, we simply refresh the page after 5 seconds.

Gitpod: Enable webpack dev server

We currently force the static webpack compilation in GitPod. This behaviour is annoying if someone changes frontend assets, because all of GitLab needs to be recompiled, which is time consuming.

This enables the normal webpack dev server, but with live reload disabled. enabling live reload is being tracked here: gitlab-development-kit#1444

Screenshots or screen recordings

N/A

How to set up and validate locally

On master:

  1. set gdk.live_reload to false in the GDK.
  2. gdk reconfigure and gdk restart webpack
  3. run gdk tail webpack
  4. navigate to a page that you haven't visited => webpack crashes

On this branch it will succeed.

MR acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

Edited by Lukas Eipert

Merge request reports

Loading