@rollup/plugin-commonjs 22.0.0-12 → 22.0.0-13

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 CHANGED
@@ -13,7 +13,7 @@
13
13
 
14
14
  ## Requirements
15
15
 
16
- This plugin requires an [LTS](https://github.com/nodejs/Release) Node version (v8.0.0+) and Rollup v1.20.0+.
16
+ This plugin requires an [LTS](https://github.com/nodejs/Release) Node version (v12.0.0+) and Rollup v2.68.0+. If you are using [`@rollup/plugin-node-resolve`](https://github.com/rollup/plugins/tree/master/packages/node-resolve), it should be v13.0.6+.
17
17
 
18
18
  ## Install
19
19
 
package/dist/cjs/index.js CHANGED
@@ -16,7 +16,7 @@ var glob__default = /*#__PURE__*/_interopDefaultLegacy(glob);
16
16
  var MagicString__default = /*#__PURE__*/_interopDefaultLegacy(MagicString);
17
17
  var isReference__default = /*#__PURE__*/_interopDefaultLegacy(isReference);
18
18
 
19
- var version = "22.0.0-12";
19
+ var version = "22.0.0-13";
20
20
  var peerDependencies = {
21
21
  rollup: "^2.68.0"
22
22
  };
@@ -667,7 +667,7 @@ function getRequireResolver(extensions, detectCyclesAndConditional) {
667
667
  resolvedSources,
668
668
  meta: { commonjs: parentMeta }
669
669
  }) {
670
- // We explicitly track ES modules to handle ciruclar imports
670
+ // We explicitly track ES modules to handle circular imports
671
671
  if (!(parentMeta && parentMeta.isCommonJS)) knownCjsModuleTypes[parentId] = false;
672
672
  if (isWrappedId(parentId, ES_IMPORT_SUFFIX)) return false;
673
673
  const parentRequires = parentMeta && parentMeta.requires;
@@ -702,7 +702,7 @@ function getRequireResolver(extensions, detectCyclesAndConditional) {
702
702
  await Promise.all(
703
703
  Object.keys(resolvedSources)
704
704
  .map((source) => resolvedSources[source])
705
- .filter(({ id }) => !parentRequireSet.has(id))
705
+ .filter(({ id, external }) => !(external || parentRequireSet.has(id)))
706
706
  .map(async (resolved) => {
707
707
  if (isWrappedId(resolved.id, ES_IMPORT_SUFFIX)) {
708
708
  return (