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: ensure userRequest stays unique (module.userRequest) #58

Merged

Conversation

timse
Copy link
Contributor

@timse timse commented Nov 14, 2017

Notable Changes

There is an issue using expose loader in combination with webpack.NamedModulesPlugin as the userRequest that is used by webpack to calculate the named modules id stays the same.

See images below for explanation and fix:

screen shot 2017-11-14 at 11 09 46 am

screen shot 2017-11-14 at 11 09 57 am

Issues

@jsf-clabot
Copy link

jsf-clabot commented Nov 14, 2017

CLA assistant check
All committers have signed the CLA.

@michael-ciniawsky michael-ciniawsky changed the title make sure userRequest stays unique fix: make sure userRequest stays unique (module.userRequest) Nov 15, 2017
Copy link
Member

@michael-ciniawsky michael-ciniawsky left a comment

Choose a reason for hiding this comment

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

👍

index.js Outdated
@@ -32,6 +32,7 @@ module.exports.pitch = function(remainingRequest) {
);
this.cacheable && this.cacheable();
if(!this.query) throw new Error("query parameter is missing");
this._module.userRequest = this._module.userRequest + ' - exposed';
Copy link
Member

Choose a reason for hiding this comment

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

Could you please add a comment marking this is as a workaround until module.libIdent() gets fixed ? :)

Copy link
Contributor Author

Choose a reason for hiding this comment

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

sure

@michael-ciniawsky
Copy link
Member

Please sign the CLA by closing and reopening the PR to trigger the CLA Bot again :)

@timse timse closed this Nov 16, 2017
@timse timse reopened this Nov 16, 2017
@timse
Copy link
Contributor Author

timse commented Nov 16, 2017

i signed it, see => https://cla.js.foundation/webpack-contrib/expose-loader?pullRequest=58
not sure what else i can do 😛

@michael-ciniawsky
Copy link
Member

michael-ciniawsky commented Nov 16, 2017

🤔 Is your email used by git (.gitconfig) && your github account the same address?

@timse
Copy link
Contributor Author

timse commented Nov 16, 2017

that was it :P sorry

@michael-ciniawsky michael-ciniawsky merged commit b45fd4c into webpack-contrib:master Nov 17, 2017
@michael-ciniawsky michael-ciniawsky changed the title fix: make sure userRequest stays unique (module.userRequest) fix: ensure userRequest stays unique (module.userRequest) Nov 17, 2017
@michael-ciniawsky
Copy link
Member

@timse Thx again 👍

@timse timse deleted the fix-named-module-issue branch November 17, 2017 20:03
@timse
Copy link
Contributor Author

timse commented Nov 17, 2017

np :)

can we release that?

@michael-ciniawsky
Copy link
Member

Sry I can't cc @d3viant0ne :)

@joshwiens
Copy link
Member

@timse - Sorry, missed this one. I'll have it out in 20 minutes.

@michael-ciniawsky michael-ciniawsky removed this from the 0.7.5 milestone Nov 18, 2017
@timse
Copy link
Contributor Author

timse commented Nov 20, 2017

no worries @d3viant0ne and thnks for the release! :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
5 participants