We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 0380796 commit 91c3a1aCopy full SHA for 91c3a1a
2 files changed
test/configCases/externals/optional-externals-umd2-mixed/index.js
@@ -0,0 +1,11 @@
1
+it("should not fail on optional externals", function() {
2
+ require("external2");
3
+ try {
4
+ require("external");
5
+ } catch(e) {
6
+ e.should.be.instanceof(Error);
7
+ e.code.should.be.eql("MODULE_NOT_FOUND");
8
+ return;
9
+ }
10
+ throw new Error("It doesn't fail");
11
+});
test/configCases/externals/optional-externals-umd2-mixed/webpack.config.js
@@ -0,0 +1,9 @@
+module.exports = {
+ output: {
+ libraryTarget: "umd2"
+ },
+ externals: {
+ external: "external",
+ external2: "fs"
+};
0 commit comments