Skip to content

feat: add WEBPACK_SERVE environment variable - #2027

Merged
rishabh3112 merged 6 commits into
masterfrom
feat/serve-var
Nov 4, 2020
Merged

rishabh3112 merged 6 commits into
masterfrom
feat/serve-var

Conversation

@rishabh3112

@rishabh3112 rishabh3112 commented Nov 3, 2020 •

Copy link
Copy Markdown
Contributor

What kind of change does this PR introduce?
Add WEBPACK_SERVE variable in environment and in main process if webpack serve is used.

Did you add tests for your changes?
Yes
If relevant, did you update the documentation?
No
Summary
Fixes #1973

Does this PR introduce a breaking change?
Yes,

  1. Exposing WEBPACK_SERVE variable which was earlier WEBPACK_DEV_SERVER when dev server was not integrated into CLI.
  2. New variable WEBPACK_SERVE is now accessable only through env argument supplied to webpack configuration of type function.

Other information
/cc @evilebottnawi

@rishabh3112
rishabh3112 requested a review from a team as a code owner November 3, 2020 03:26
Comment thread packages/serve/src/index.ts Resolved
Comment thread packages/serve/src/index.ts Resolved
Comment thread packages/serve/src/parseArgs.ts Resolved

@alexander-akait alexander-akait left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

/cc @webpack/cli-team

@rishabh3112
rishabh3112 merged commit ea369a9 into master Nov 4, 2020
@rishabh3112
rishabh3112 deleted the feat/serve-var branch November 4, 2020 16:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

The WEBPACK_DEV_SERVER environment variable is not set when running "webpack serve"

5 participants