chore: convert dev server to webpack plugin by rishabh3112 · Pull Request #3850 · webpack/webpack-dev-server

Conversation

@rishabh3112

  • 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?

WIP

Motivation / Use-Case

Dev Server should be a plugin

Breaking Changes

Nope

Additional Info

N/A

@codecov

@rishabh3112

@alexander-akait let me know if there any custom hooks required to be implemented here.

alexander-akait

alexander-akait

rishabh3112


let started = false;

compiler.hooks.watchRun.tapPromise(pluginName, async () => {

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We should enable watch before taping into watchRun hook.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, plugin should work only for webpack watch/webpack serve, but I am afraid it is so late to override fs, need think more about it

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yep, in my roadmap on the next week

Reviewers

@anshumanv anshumanv Awaiting requested review from anshumanv

@hiroppy hiroppy Awaiting requested review from hiroppy

@knagaitsev knagaitsev Awaiting requested review from knagaitsev

@snitin315 snitin315 Awaiting requested review from snitin315

@alexander-akait alexander-akait Awaiting requested review from alexander-akait

At least 1 approving review is required to merge this pull request.

2 participants

@rishabh3112 @alexander-akait