@atlaspack/core 2.16.2-canary.115 → 2.16.2-canary.117

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.
@@ -4,6 +4,13 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.propagateSymbols = propagateSymbols;
7
+ function _featureFlags() {
8
+ const data = require("@atlaspack/feature-flags");
9
+ _featureFlags = function () {
10
+ return data;
11
+ };
12
+ return data;
13
+ }
7
14
  function _assert() {
8
15
  const data = _interopRequireDefault(require("assert"));
9
16
  _assert = function () {
@@ -72,6 +79,13 @@ function propagateSymbols({
72
79
 
73
80
  // Propagate the requested symbols down from the root to the leaves
74
81
  propagateSymbolsDown(assetGraph, changedAssets, assetGroupsWithRemovedParents, (assetNode, incomingDeps, outgoingDeps) => {
82
+ if ((0, _featureFlags().getFeatureFlag)('emptyFileStarRexportFix')) {
83
+ if (assetNode.value.meta.emptyFileStarReexport && incomingDeps.every(d => d.value.specifierType === _types.SpecifierType.esm)) {
84
+ var _assetNode$value$symb;
85
+ (_assetNode$value$symb = assetNode.value.symbols) === null || _assetNode$value$symb === void 0 || _assetNode$value$symb.delete('*');
86
+ }
87
+ }
88
+
75
89
  // exportSymbol -> identifier
76
90
  let assetSymbols = assetNode.value.symbols;
77
91
  // identifier -> exportSymbol
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaspack/core",
3
- "version": "2.16.2-canary.115+c71e6b3fb",
3
+ "version": "2.16.2-canary.117+becf977f6",
4
4
  "license": "(MIT OR Apache-2.0)",
5
5
  "publishConfig": {
6
6
  "access": "public"
@@ -21,21 +21,21 @@
21
21
  "check-ts": "tsc --noEmit index.d.ts"
22
22
  },
23
23
  "dependencies": {
24
- "@atlaspack/build-cache": "2.13.3-canary.183+c71e6b3fb",
25
- "@atlaspack/cache": "3.1.1-canary.115+c71e6b3fb",
26
- "@atlaspack/diagnostic": "2.14.1-canary.183+c71e6b3fb",
27
- "@atlaspack/events": "2.14.1-canary.183+c71e6b3fb",
28
- "@atlaspack/feature-flags": "2.14.1-canary.183+c71e6b3fb",
29
- "@atlaspack/fs": "2.14.5-canary.115+c71e6b3fb",
30
- "@atlaspack/graph": "3.4.1-canary.183+c71e6b3fb",
31
- "@atlaspack/logger": "2.14.5-canary.115+c71e6b3fb",
32
- "@atlaspack/package-manager": "2.14.5-canary.115+c71e6b3fb",
33
- "@atlaspack/plugin": "2.14.5-canary.115+c71e6b3fb",
34
- "@atlaspack/profiler": "2.14.1-canary.183+c71e6b3fb",
35
- "@atlaspack/rust": "3.2.1-canary.115+c71e6b3fb",
36
- "@atlaspack/types": "2.14.5-canary.115+c71e6b3fb",
37
- "@atlaspack/utils": "2.14.5-canary.115+c71e6b3fb",
38
- "@atlaspack/workers": "2.14.5-canary.115+c71e6b3fb",
24
+ "@atlaspack/build-cache": "2.13.3-canary.185+becf977f6",
25
+ "@atlaspack/cache": "3.1.1-canary.117+becf977f6",
26
+ "@atlaspack/diagnostic": "2.14.1-canary.185+becf977f6",
27
+ "@atlaspack/events": "2.14.1-canary.185+becf977f6",
28
+ "@atlaspack/feature-flags": "2.14.1-canary.185+becf977f6",
29
+ "@atlaspack/fs": "2.14.5-canary.117+becf977f6",
30
+ "@atlaspack/graph": "3.4.1-canary.185+becf977f6",
31
+ "@atlaspack/logger": "2.14.5-canary.117+becf977f6",
32
+ "@atlaspack/package-manager": "2.14.5-canary.117+becf977f6",
33
+ "@atlaspack/plugin": "2.14.5-canary.117+becf977f6",
34
+ "@atlaspack/profiler": "2.14.1-canary.185+becf977f6",
35
+ "@atlaspack/rust": "3.2.1-canary.117+becf977f6",
36
+ "@atlaspack/types": "2.14.5-canary.117+becf977f6",
37
+ "@atlaspack/utils": "2.14.5-canary.117+becf977f6",
38
+ "@atlaspack/workers": "2.14.5-canary.117+becf977f6",
39
39
  "@mischnic/json-sourcemap": "^0.1.0",
40
40
  "@parcel/source-map": "^2.1.1",
41
41
  "base-x": "^3.0.8",
@@ -60,5 +60,5 @@
60
60
  "./src/serializerCore.js": "./src/serializerCore.browser.js"
61
61
  },
62
62
  "type": "commonjs",
63
- "gitHead": "c71e6b3fbc0f6981809a8090a1a4ced50413a349"
63
+ "gitHead": "becf977f625d5ee46dae3d4c679f173bf5f40cc0"
64
64
  }
@@ -3,6 +3,7 @@
3
3
  import type {ContentKey, NodeId} from '@atlaspack/graph';
4
4
  import type {Meta, Symbol} from '@atlaspack/types';
5
5
  import type {Diagnostic} from '@atlaspack/diagnostic';
6
+ import {getFeatureFlag} from '@atlaspack/feature-flags';
6
7
  import type {
7
8
  AssetNode,
8
9
  DependencyNode,
@@ -17,7 +18,7 @@ import {setEqual} from '@atlaspack/utils';
17
18
  import logger from '@atlaspack/logger';
18
19
  import {md, convertSourceLocationToHighlight} from '@atlaspack/diagnostic';
19
20
  import {instrument} from '@atlaspack/logger';
20
- import {BundleBehavior, Priority} from './types';
21
+ import {BundleBehavior, Priority, SpecifierType} from './types';
21
22
  import {fromProjectPathRelative, fromProjectPath} from './projectPath';
22
23
 
23
24
  export function propagateSymbols({
@@ -62,6 +63,17 @@ export function propagateSymbols({
62
63
  changedAssets,
63
64
  assetGroupsWithRemovedParents,
64
65
  (assetNode, incomingDeps, outgoingDeps) => {
66
+ if (getFeatureFlag('emptyFileStarRexportFix')) {
67
+ if (
68
+ assetNode.value.meta.emptyFileStarReexport &&
69
+ incomingDeps.every(
70
+ (d) => d.value.specifierType === SpecifierType.esm,
71
+ )
72
+ ) {
73
+ assetNode.value.symbols?.delete('*');
74
+ }
75
+ }
76
+
65
77
  // exportSymbol -> identifier
66
78
  let assetSymbols: ?$ReadOnlyMap<
67
79
  Symbol,