@rollup/plugin-commonjs 28.0.3 → 28.0.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +5 -1
- package/dist/cjs/index.js +7 -3
- package/dist/es/index.js +7 -3
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -303,7 +303,11 @@ For these situations, you can change Rollup's behaviour either globally or per m
|
|
|
303
303
|
var f = n.default;
|
|
304
304
|
if (typeof f == 'function') {
|
|
305
305
|
var a = function a() {
|
|
306
|
-
|
|
306
|
+
var isInstance = false;
|
|
307
|
+
try {
|
|
308
|
+
isInstance = this instanceof a;
|
|
309
|
+
} catch {}
|
|
310
|
+
if (isInstance) {
|
|
307
311
|
return Reflect.construct(f, arguments, this.constructor);
|
|
308
312
|
}
|
|
309
313
|
return f.apply(this, arguments);
|
package/dist/cjs/index.js
CHANGED
|
@@ -11,7 +11,7 @@ var estreeWalker = require('estree-walker');
|
|
|
11
11
|
var MagicString = require('magic-string');
|
|
12
12
|
var isReference = require('is-reference');
|
|
13
13
|
|
|
14
|
-
var version = "28.0.
|
|
14
|
+
var version = "28.0.5";
|
|
15
15
|
var peerDependencies = {
|
|
16
16
|
rollup: "^2.68.0||^3.0.0||^4.0.0"
|
|
17
17
|
};
|
|
@@ -183,7 +183,7 @@ function getDynamicRequireModules(patterns, dynamicRequireRoot) {
|
|
|
183
183
|
.withBasePath()
|
|
184
184
|
.withDirs()
|
|
185
185
|
.glob(isNegated ? pattern.substr(1) : pattern)
|
|
186
|
-
.crawl()
|
|
186
|
+
.crawl(path.relative('.', dynamicRequireRoot))
|
|
187
187
|
.sync()
|
|
188
188
|
.sort((a, b) => a.localeCompare(b, 'en'))) {
|
|
189
189
|
const resolvedPath = path.resolve(path$1);
|
|
@@ -380,7 +380,11 @@ export function getAugmentedNamespace(n) {
|
|
|
380
380
|
var f = n.default;
|
|
381
381
|
if (typeof f == "function") {
|
|
382
382
|
var a = function a () {
|
|
383
|
-
|
|
383
|
+
var isInstance = false;
|
|
384
|
+
try {
|
|
385
|
+
isInstance = this instanceof a;
|
|
386
|
+
} catch {}
|
|
387
|
+
if (isInstance) {
|
|
384
388
|
return Reflect.construct(f, arguments, this.constructor);
|
|
385
389
|
}
|
|
386
390
|
return f.apply(this, arguments);
|
package/dist/es/index.js
CHANGED
|
@@ -7,7 +7,7 @@ import { walk } from 'estree-walker';
|
|
|
7
7
|
import MagicString from 'magic-string';
|
|
8
8
|
import isReference from 'is-reference';
|
|
9
9
|
|
|
10
|
-
var version = "28.0.
|
|
10
|
+
var version = "28.0.5";
|
|
11
11
|
var peerDependencies = {
|
|
12
12
|
rollup: "^2.68.0||^3.0.0||^4.0.0"
|
|
13
13
|
};
|
|
@@ -179,7 +179,7 @@ function getDynamicRequireModules(patterns, dynamicRequireRoot) {
|
|
|
179
179
|
.withBasePath()
|
|
180
180
|
.withDirs()
|
|
181
181
|
.glob(isNegated ? pattern.substr(1) : pattern)
|
|
182
|
-
.crawl()
|
|
182
|
+
.crawl(relative('.', dynamicRequireRoot))
|
|
183
183
|
.sync()
|
|
184
184
|
.sort((a, b) => a.localeCompare(b, 'en'))) {
|
|
185
185
|
const resolvedPath = resolve(path);
|
|
@@ -376,7 +376,11 @@ export function getAugmentedNamespace(n) {
|
|
|
376
376
|
var f = n.default;
|
|
377
377
|
if (typeof f == "function") {
|
|
378
378
|
var a = function a () {
|
|
379
|
-
|
|
379
|
+
var isInstance = false;
|
|
380
|
+
try {
|
|
381
|
+
isInstance = this instanceof a;
|
|
382
|
+
} catch {}
|
|
383
|
+
if (isInstance) {
|
|
380
384
|
return Reflect.construct(f, arguments, this.constructor);
|
|
381
385
|
}
|
|
382
386
|
return f.apply(this, arguments);
|