Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@evenstensberg
Copy link
Member

What kind of change does this PR introduce?
#1023
Did you add tests for your changes?
Yes
If relevant, did you update the documentation?
N/A
Summary

Tries to resolve validation for both versions.

Does this PR introduce a breaking change?
no

Other information

@sokra could you verify? Tested locally, removed the if/else but you might be aware of anymore pitfalls.

Copy link
Member

@sokra sokra left a comment

Choose a reason for hiding this comment

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

Looks good to me, haven't tried to run it

Copy link
Contributor

@ematipico ematipico left a comment

Choose a reason for hiding this comment

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

Code wise looks good. I would move it into a separate a function so we can test it

const error = new WebpackOptionsValidationError(webpackConfigurationValidationErrors);
console.error(error.message, `\nReceived: ${typeof options} : ${JSON.stringify(options, null, 2)}`);
process.exit(-1); // eslint-disable-line
let error;
Copy link
Contributor

Choose a reason for hiding this comment

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

Could you make a function out of it and export it? So we can test it and make sure 100% that it works.

Copy link
Member Author

Choose a reason for hiding this comment

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

yup will do

@webpack-bot
Copy link

Thank you for your pull request! The most important CI builds succeeded, we’ll review the pull request soon.

Copy link
Contributor

@ematipico ematipico left a comment

Choose a reason for hiding this comment

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

We should add the test now

@webpack-bot
Copy link

@evenstensberg Thanks for your update.

I labeled the Pull Request so reviewers will review it again.

@ematipico Please review the new changes.

@evenstensberg
Copy link
Member Author

Thanks for reviewing @ematipico . Singing this of and releasing 💙

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.

5 participants