-
Notifications
You must be signed in to change notification settings - Fork 29
Add external loader plugin from webpack-contrib #31
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
Conversation
Codecov Report
@@ Coverage Diff @@
## master #31 +/- ##
==========================================
- Coverage 59.17% 57.42% -1.75%
==========================================
Files 8 8
Lines 436 451 +15
Branches 93 101 +8
==========================================
+ Hits 258 259 +1
- Misses 178 192 +14
Continue to review full report at Codecov.
|
Documentation such as https://github.com/dojo/cli-build-webpack#interop-with-external-libraries should probably be updated in this PR when this change is landed. |
@maier49 @mwistrand There are two open PRs for supporting externals, this and #98 - Do you think we could consolidate them down into a single PR and make any requested changes in the reviews? |
Closing in favor of #98. |
Matt Wistrand seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please add the email address used for this commit to your account. |
41b56bb
to
1e3dd3d
Compare
- Add ExternalLoaderPlugin from webpack-contrib - TEMP: Add webpack-contrib deps to package.json and test-app/package.json - Update unix fixtures - Reset package-lock.json so it does not throw errors on install
1e3dd3d
to
2ac549d
Compare
- Remove unneeded node modules - Add `externals` to `test-app/.dojorc-pwa`
package.json
Outdated
@@ -112,6 +112,7 @@ | |||
"express": "4.16.2", | |||
"extract-text-webpack-plugin": "3.0.2", | |||
"file-loader": "1.1.5", | |||
"html-webpack-include-assets-plugin": "1.0.2", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is this used?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nope. I thought I deleted that.
I have now verified the most recent changes with a local sandbox app on both Windows and macOS. |
Resolves #7. Requires a patch release of
webpack-contrib
, which this PR makes up for by directly adding dependencies topackage.json
andtest-app/package.json
(these will be removed prior to merging).Adds the
ExternalLoaderPlugin
from@dojo/webpack-contrib
, allowing external dependencies that cannot be loaded with webpack to be injected from outside the build. There is a nearly identical implementation in@dojo/cli-build-webpack
, but with two notable differences:amd {request}
toexternals
callback in v3 webpack/webpack#6302)dojo/_base/lang
can be excluded directly without needing to exclude all ofdojo
ordojo/_base
.