@atlaspack/feature-flags 2.15.0 → 2.16.0

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/CHANGELOG.md CHANGED
@@ -1,5 +1,28 @@
1
1
  # @atlaspack/feature-flags
2
2
 
3
+ ## 2.16.0
4
+
5
+ ### Minor Changes
6
+
7
+ - [#582](https://github.com/atlassian-labs/atlaspack/pull/582) [`f4da1e1`](https://github.com/atlassian-labs/atlaspack/commit/f4da1e120e73eeb5e8b8927f05e88f04d6148c7b) Thanks [@matt-koko](https://github.com/matt-koko)! - Export DEFAULT_FEATURE_FLAGS so it will be included in the associate type declaration file and able to be imported elsewhere.
8
+
9
+ This will enable patterns like:
10
+
11
+ ```
12
+ import type { FeatureFlags } from '@atlaspack/feature-flags';
13
+ import { DEFAULT_FEATURE_FLAGS } from '@atlaspack/feature-flags';
14
+ ```
15
+
16
+ ### Patch Changes
17
+
18
+ - [#503](https://github.com/atlassian-labs/atlaspack/pull/503) [`209692f`](https://github.com/atlassian-labs/atlaspack/commit/209692ffb11eae103a0d65c5e1118a5aa1625818) Thanks [@JakeLane](https://github.com/JakeLane)! - Fix conditional bundling reporter when condition is reused
19
+
20
+ ## 2.15.1
21
+
22
+ ### Patch Changes
23
+
24
+ - [#551](https://github.com/atlassian-labs/atlaspack/pull/551) [`30f6017`](https://github.com/atlassian-labs/atlaspack/commit/30f60175ba4d272c5fc193973c63bc298584775b) Thanks [@yamadapc](https://github.com/yamadapc)! - Log request tracker invalidation counts on start-up
25
+
3
26
  ## 2.15.0
4
27
 
5
28
  ### Minor Changes
package/lib/index.js CHANGED
@@ -25,11 +25,15 @@ const DEFAULT_FEATURE_FLAGS = exports.DEFAULT_FEATURE_FLAGS = {
25
25
  inlineBundlesSourceMapFixes: false,
26
26
  conditionalBundlingNestedRuntime: false,
27
27
  patchProjectPaths: false,
28
- cachePerformanceImprovements: false,
28
+ cachePerformanceImprovements: process.env.NODE_ENV === 'test',
29
+ granularTsConfigInvalidation: false,
29
30
  inlineStringReplacementPerf: false,
30
31
  conditionalBundlingAsyncRuntime: false,
32
+ // Default to true as it's a monitoring change. Can be turned off if necessary.
33
+ verboseRequestInvalidationStats: true,
31
34
  conditionalBundlingReporterDuplicateFix: false,
32
- resolveBundlerConfigFromCwd: false
35
+ resolveBundlerConfigFromCwd: false,
36
+ conditionalBundlingReporterSameConditionFix: false
33
37
  };
34
38
  let featureFlagValues = {
35
39
  ...DEFAULT_FEATURE_FLAGS
package/lib/types.d.ts CHANGED
@@ -43,6 +43,11 @@ export type FeatureFlags = {
43
43
  */
44
44
  vcsMode: ConsistencyCheckFeatureFlagValue;
45
45
 
46
+ /**
47
+ * Enable granular TS config invalidation
48
+ */
49
+ granularTsConfigInvalidation: boolean;
50
+
46
51
  /**
47
52
  * Refactor cache to:
48
53
  * - Split writes into multiple entries
@@ -62,6 +67,11 @@ export type FeatureFlags = {
62
67
  */
63
68
  reduceResolverStringCreation: boolean;
64
69
 
70
+ /**
71
+ * Add verbose metrics for request tracker invalidation
72
+ */
73
+ verboseRequestInvalidationStats: boolean;
74
+
65
75
  /**
66
76
  * Fixes source maps for inline bundles
67
77
  */
@@ -97,5 +107,11 @@ export type FeatureFlags = {
97
107
  * Enable resolution of bundler config starting from the CWD
98
108
  */
99
109
  resolveBundlerConfigFromCwd: boolean;
110
+
111
+ /**
112
+ * Fix a bug where the conditional manifest reporter would drop bundles that have the same condition
113
+ */
114
+ conditionalBundlingReporterSameConditionFix: boolean;
100
115
  };
101
116
  export type ConsistencyCheckFeatureFlagValue = "NEW" | "OLD" | "NEW_AND_CHECK" | "OLD_AND_CHECK";
117
+ export declare var DEFAULT_FEATURE_FLAGS: FeatureFlags;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaspack/feature-flags",
3
- "version": "2.15.0",
3
+ "version": "2.16.0",
4
4
  "description": "Provides internal feature-flags for the atlaspack codebase.",
5
5
  "license": "(MIT OR Apache-2.0)",
6
6
  "publishConfig": {
package/src/index.js CHANGED
@@ -20,11 +20,15 @@ export const DEFAULT_FEATURE_FLAGS: FeatureFlags = {
20
20
  inlineBundlesSourceMapFixes: false,
21
21
  conditionalBundlingNestedRuntime: false,
22
22
  patchProjectPaths: false,
23
- cachePerformanceImprovements: false,
23
+ cachePerformanceImprovements: process.env.NODE_ENV === 'test',
24
+ granularTsConfigInvalidation: false,
24
25
  inlineStringReplacementPerf: false,
25
26
  conditionalBundlingAsyncRuntime: false,
27
+ // Default to true as it's a monitoring change. Can be turned off if necessary.
28
+ verboseRequestInvalidationStats: true,
26
29
  conditionalBundlingReporterDuplicateFix: false,
27
30
  resolveBundlerConfigFromCwd: false,
31
+ conditionalBundlingReporterSameConditionFix: false,
28
32
  };
29
33
 
30
34
  let featureFlagValues: FeatureFlags = {...DEFAULT_FEATURE_FLAGS};
package/src/types.js CHANGED
@@ -37,6 +37,10 @@ export type FeatureFlags = {|
37
37
  * - NEW: Return VCS result, but don't call watchman
38
38
  */
39
39
  vcsMode: ConsistencyCheckFeatureFlagValue,
40
+ /**
41
+ * Enable granular TS config invalidation
42
+ */
43
+ granularTsConfigInvalidation: boolean,
40
44
  /**
41
45
  * Refactor cache to:
42
46
  * - Split writes into multiple entries
@@ -53,6 +57,10 @@ export type FeatureFlags = {|
53
57
  * conversions
54
58
  */
55
59
  reduceResolverStringCreation: boolean,
60
+ /**
61
+ * Add verbose metrics for request tracker invalidation
62
+ */
63
+ verboseRequestInvalidationStats: boolean,
56
64
  /**
57
65
  * Fixes source maps for inline bundles
58
66
  */
@@ -82,6 +90,10 @@ export type FeatureFlags = {|
82
90
  * Enable resolution of bundler config starting from the CWD
83
91
  */
84
92
  resolveBundlerConfigFromCwd: boolean,
93
+ /**
94
+ * Fix a bug where the conditional manifest reporter would drop bundles that have the same condition
95
+ */
96
+ conditionalBundlingReporterSameConditionFix: boolean,
85
97
  |};
86
98
 
87
99
  export type ConsistencyCheckFeatureFlagValue =
@@ -89,3 +101,5 @@ export type ConsistencyCheckFeatureFlagValue =
89
101
  | 'OLD'
90
102
  | 'NEW_AND_CHECK'
91
103
  | 'OLD_AND_CHECK';
104
+
105
+ declare export var DEFAULT_FEATURE_FLAGS: FeatureFlags;