@atlaspack/feature-flags 2.25.2-dev-ts-project-refs-d30e9754f.0 → 2.25.2
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 +18 -0
- package/dist/index.js +71 -11
- package/lib/index.js +72 -12
- package/lib/types/index.d.ts +71 -11
- package/package.json +3 -4
- package/src/index.ts +72 -13
- package/tsconfig.tsbuildinfo +1 -1
- package/LICENSE +0 -201
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,23 @@
|
|
|
1
1
|
# @atlaspack/feature-flags
|
|
2
2
|
|
|
3
|
+
## 2.25.2
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [#790](https://github.com/atlassian-labs/atlaspack/pull/790) [`0207171`](https://github.com/atlassian-labs/atlaspack/commit/0207171e59e985c51e105aec2e0a99de174374bd) Thanks [@benjervis](https://github.com/benjervis)! - Clean up the `unusedComputedPropertyFix` feature flag
|
|
8
|
+
|
|
9
|
+
- [#791](https://github.com/atlassian-labs/atlaspack/pull/791) [`10ee3fa`](https://github.com/atlassian-labs/atlaspack/commit/10ee3fa5b75a92acde8973673d9b3c5b6f3958e5) Thanks [@benjervis](https://github.com/benjervis)! - Remove emptyFileStarRexportFix and make the flagged behaviour standard.
|
|
10
|
+
|
|
11
|
+
See PR [#685][pr] for details on the change.
|
|
12
|
+
|
|
13
|
+
[pr]: https://github.com/atlassian-labs/atlaspack/pull/685
|
|
14
|
+
|
|
15
|
+
- [#800](https://github.com/atlassian-labs/atlaspack/pull/800) [`1180103`](https://github.com/atlassian-labs/atlaspack/commit/118010351ed444f8178988afb3f77807154dd933) Thanks [@mattcompiles](https://github.com/mattcompiles)! - Fix errors when creating diagnostics with relative file paths
|
|
16
|
+
|
|
17
|
+
BREAKING CHANGE: The `remapSourceLocation` API in `@atlaspack/utils` now requires the project root
|
|
18
|
+
|
|
19
|
+
- [#781](https://github.com/atlassian-labs/atlaspack/pull/781) [`2bc93b1`](https://github.com/atlassian-labs/atlaspack/commit/2bc93b17cea07fd7cbb68acec84d8471345a22b4) Thanks [@matt-koko](https://github.com/matt-koko)! - add attribution to feature flags and eslint rule to enforce attribution convention
|
|
20
|
+
|
|
3
21
|
## 2.25.1
|
|
4
22
|
|
|
5
23
|
### Patch Changes
|
package/dist/index.js
CHANGED
|
@@ -18,24 +18,34 @@ exports.DEFAULT_FEATURE_FLAGS = {
|
|
|
18
18
|
exampleConsistencyCheckFeature: 'OLD',
|
|
19
19
|
/**
|
|
20
20
|
* Rust backed requests
|
|
21
|
+
*
|
|
22
|
+
* @author Matt Jones <mjones4@atlassian.com>
|
|
21
23
|
*/
|
|
22
24
|
atlaspackV3: false,
|
|
23
25
|
/**
|
|
24
26
|
* Use node.js implementation of @parcel/watcher watchman backend
|
|
27
|
+
*
|
|
28
|
+
* @author Pedro Tacla Yamada <pyamada@atlassian.com>
|
|
25
29
|
*/
|
|
26
30
|
useWatchmanWatcher: false,
|
|
27
31
|
/**
|
|
28
32
|
* Configure runtime to enable retriable dynamic imports
|
|
33
|
+
*
|
|
34
|
+
* @author David Alsh <dalsh@atlassian.com>
|
|
29
35
|
*/
|
|
30
36
|
importRetry: false,
|
|
31
37
|
/**
|
|
32
38
|
* Fixes quadratic cache invalidation issue
|
|
39
|
+
*
|
|
40
|
+
* @author Pedro Tacla Yamada <pyamada@atlassian.com>
|
|
33
41
|
*/
|
|
34
42
|
fixQuadraticCacheInvalidation: 'OLD',
|
|
35
43
|
/**
|
|
36
44
|
* Enables an experimental "conditional bundling" API - this allows the use of `importCond` syntax
|
|
37
45
|
* in order to have (consumer) feature flag driven bundling. This feature is very experimental,
|
|
38
46
|
* and requires server-side support.
|
|
47
|
+
*
|
|
48
|
+
* @author Jake Lane <jlane2@atlassian.com>
|
|
39
49
|
*/
|
|
40
50
|
conditionalBundlingApi: false,
|
|
41
51
|
/**
|
|
@@ -43,6 +53,8 @@ exports.DEFAULT_FEATURE_FLAGS = {
|
|
|
43
53
|
* - OLD - default value, return watchman result
|
|
44
54
|
* - NEW_AND_CHECK - Return VCS result but still call watchman
|
|
45
55
|
* - NEW: Return VCS result, but don't call watchman
|
|
56
|
+
*
|
|
57
|
+
* @author Celeste Carloni <ccarloni@atlassian.com>
|
|
46
58
|
*/
|
|
47
59
|
vcsMode: 'OLD',
|
|
48
60
|
/**
|
|
@@ -50,126 +62,174 @@ exports.DEFAULT_FEATURE_FLAGS = {
|
|
|
50
62
|
* - Split writes into multiple entries
|
|
51
63
|
* - Remove "large file blob" writes
|
|
52
64
|
* - Reduce size of the caches by deduplicating data
|
|
65
|
+
*
|
|
66
|
+
* @author Pedro Tacla Yamada <pyamada@atlassian.com>
|
|
53
67
|
*/
|
|
54
68
|
cachePerformanceImprovements: process.env.ATLASPACK_BUILD_ENV === 'test',
|
|
55
69
|
/**
|
|
56
70
|
* Deduplicates environments across cache / memory entities
|
|
71
|
+
*
|
|
72
|
+
* @author Pedro Tacla Yamada <pyamada@atlassian.com>
|
|
57
73
|
*/
|
|
58
74
|
environmentDeduplication: false,
|
|
59
75
|
/**
|
|
60
76
|
* Enable scanning for the presence of loadable to determine side effects
|
|
77
|
+
*
|
|
78
|
+
* @author Ben Jervis <bjervis@atlassian.com>
|
|
61
79
|
*/
|
|
62
80
|
loadableSideEffects: false,
|
|
63
81
|
/**
|
|
64
82
|
* Enable performance optimization for the resolver specifier to_string
|
|
65
83
|
* conversions
|
|
84
|
+
*
|
|
85
|
+
* @author Pedro Tacla Yamada <pyamada@atlassian.com>
|
|
66
86
|
*/
|
|
67
87
|
reduceResolverStringCreation: false,
|
|
68
88
|
/**
|
|
69
89
|
* Add verbose metrics for request tracker invalidation.
|
|
70
90
|
* Default to true as it's a monitoring change. Can be turned off if necessary.
|
|
91
|
+
*
|
|
92
|
+
* @author Pedro Tacla Yamada <pyamada@atlassian.com>
|
|
71
93
|
*/
|
|
72
94
|
verboseRequestInvalidationStats: true,
|
|
73
95
|
/**
|
|
74
96
|
* Fixes source maps for inline bundles
|
|
97
|
+
*
|
|
98
|
+
* @author Pedro Tacla Yamada <pyamada@atlassian.com>
|
|
75
99
|
*/
|
|
76
100
|
inlineBundlesSourceMapFixes: false,
|
|
77
101
|
/** Enable patch project paths. This will patch the project paths to be relative to the project root.
|
|
78
102
|
* This feature is experimental and should not be used in production. It will used to test downloadble cache artefacts.
|
|
103
|
+
*
|
|
104
|
+
* @author Celeste Carloni <ccarloni@atlassian.com>
|
|
79
105
|
*/
|
|
80
106
|
patchProjectPaths: false,
|
|
81
107
|
/**
|
|
82
108
|
* Enables optimized inline string replacement perf for the packager.
|
|
83
109
|
* Used heavily for inline bundles.
|
|
110
|
+
*
|
|
111
|
+
* @author Matt Jones <mjones4@atlassian.com>
|
|
84
112
|
*/
|
|
85
113
|
inlineStringReplacementPerf: false,
|
|
86
114
|
/**
|
|
87
115
|
* Enable resolution of bundler config starting from the CWD
|
|
116
|
+
*
|
|
117
|
+
* @author Ben Jervis <bjervis@atlassian.com>
|
|
88
118
|
*/
|
|
89
119
|
resolveBundlerConfigFromCwd: false,
|
|
90
120
|
/**
|
|
91
121
|
* Enable a setting that allows for more assets to be scope hoisted, if
|
|
92
122
|
* they're safe to do so.
|
|
123
|
+
*
|
|
124
|
+
* @author Ben Jervis <bjervis@atlassian.com>
|
|
93
125
|
*/
|
|
94
126
|
applyScopeHoistingImprovement: false,
|
|
95
127
|
/**
|
|
96
128
|
* Enable a change where a constant module only have the namespacing object added in bundles where it is required
|
|
129
|
+
*
|
|
130
|
+
* @author Marcin Szczepanski <mszczepanski@atlassian.com>
|
|
97
131
|
*/
|
|
98
132
|
inlineConstOptimisationFix: false,
|
|
99
133
|
/**
|
|
100
134
|
* Improves/fixes HMR behaviour by:
|
|
101
135
|
* - Fixing HMR behaviour with lazy bundle edges
|
|
102
136
|
* - Moving the functionality of the react-refresh runtime into the react-refresh-wrap transformer
|
|
137
|
+
*
|
|
138
|
+
* @author Marcin Szczepanski <mszczepanski@atlassian.com>
|
|
103
139
|
*/
|
|
104
140
|
hmrImprovements: false,
|
|
105
|
-
/**
|
|
106
|
-
* Fixes a bug where imported objects that are accessed with non-static
|
|
107
|
-
* properties (e.g. `CONSTANTS['api_' + endpoint`]) would not be recognised as
|
|
108
|
-
* being used, and thus not included in the bundle.
|
|
109
|
-
*/
|
|
110
|
-
unusedComputedPropertyFix: process.env.ATLASPACK_BUILD_ENV === 'test',
|
|
111
|
-
/**
|
|
112
|
-
* Fixes an issue where star re-exports of empty files (usually occurring in compiled typescript libraries)
|
|
113
|
-
* could cause exports to undefined at runtime.
|
|
114
|
-
*/
|
|
115
|
-
emptyFileStarRexportFix: process.env.ATLASPACK_BUILD_ENV === 'test',
|
|
116
141
|
/**
|
|
117
142
|
* Enables the new packaging progress CLI experience
|
|
143
|
+
*
|
|
144
|
+
* @author Matt Jones <mjones4@atlassian.com>
|
|
118
145
|
*/
|
|
119
146
|
cliProgressReportingImprovements: false,
|
|
120
147
|
/**
|
|
121
148
|
* Adds support for `webpackChunkName` comments in dynamic imports.
|
|
122
149
|
* Imports with the same `webpackChunkName` will be bundled together.
|
|
150
|
+
*
|
|
151
|
+
* @author Ben Jervis <bjervis@atlassian.com>
|
|
123
152
|
*/
|
|
124
153
|
supportWebpackChunkName: process.env.ATLASPACK_BUILD_ENV === 'test',
|
|
125
154
|
/**
|
|
126
155
|
* Enable a change to the conditional bundling loader to use a fallback bundle loading if the expected scripts aren't found
|
|
127
156
|
*
|
|
128
157
|
* Split into two flags, to allow usage in the dev or prod packagers separately
|
|
158
|
+
*
|
|
159
|
+
* @author Jake Lane <jlane2@atlassian.com>
|
|
129
160
|
*/
|
|
130
161
|
condbDevFallbackDev: false,
|
|
162
|
+
/**
|
|
163
|
+
*
|
|
164
|
+
* @author Jake Lane <jlane2@atlassian.com>
|
|
165
|
+
*/
|
|
131
166
|
condbDevFallbackProd: false,
|
|
132
167
|
/**
|
|
133
168
|
* Enable the new incremental bundling versioning logic which determines whether
|
|
134
169
|
* a full bundling pass is required based on the AssetGraph's bundlingVersion.
|
|
170
|
+
*
|
|
171
|
+
* @author Pedro Tacla Yamada <pyamada@atlassian.com>
|
|
135
172
|
*/
|
|
136
173
|
incrementalBundlingVersioning: process.env.ATLASPACK_BUILD_ENV === 'test',
|
|
137
174
|
/**
|
|
138
175
|
* Remove redundant shared bundles that are no longer required after merging
|
|
139
176
|
* async bundles.
|
|
177
|
+
*
|
|
178
|
+
* @author Matt Jones <mjones4@atlassian.com>
|
|
140
179
|
*/
|
|
141
180
|
removeRedundantSharedBundles: process.env.ATLASPACK_BUILD_ENV === 'test',
|
|
142
181
|
/**
|
|
143
182
|
* When enabled, single file output bundles have a stable name
|
|
183
|
+
*
|
|
184
|
+
* @author Marcin Szczepanski <mszczepanski@atlassian.com>
|
|
144
185
|
*/
|
|
145
186
|
singleFileOutputStableName: process.env.ATLASPACK_BUILD_ENV === 'test',
|
|
146
187
|
/**
|
|
147
188
|
* Enable optimised prelude for the ScopeHoistingPackager.
|
|
189
|
+
*
|
|
190
|
+
* @author Jake Lane <jlane2@atlassian.com>
|
|
148
191
|
*/
|
|
149
192
|
useNewPrelude: false,
|
|
150
193
|
/**
|
|
151
194
|
* Enable a fix for applyScopeHoistingImprovement that allows assets to still
|
|
152
195
|
* be at the top level of the bundle.
|
|
196
|
+
*
|
|
197
|
+
* @author Ben Jervis <bjervis@atlassian.com>
|
|
153
198
|
*/
|
|
154
199
|
applyScopeHoistingImprovementV2: false,
|
|
155
200
|
/**
|
|
156
201
|
* When enabled, if both explicit entries and explicit targets are specified,
|
|
157
202
|
* the source properties of those targets are used as filters against the base entries.
|
|
158
203
|
* This allows building only specific entries for specific targets.
|
|
204
|
+
*
|
|
205
|
+
* @author Marcin Szczepanski <mszczepanski@atlassian.com>
|
|
159
206
|
*/
|
|
160
207
|
allowExplicitTargetEntries: process.env.ATLASPACK_BUILD_ENV === 'test',
|
|
161
208
|
/**
|
|
162
209
|
* When enabled, the packager will avoid using the binding helper for exports where possible.
|
|
210
|
+
*
|
|
211
|
+
* @author Jake Lane <jlane2@atlassian.com>
|
|
163
212
|
*/
|
|
164
213
|
exportsRebindingOptimisation: false,
|
|
165
214
|
/**
|
|
166
215
|
* When enabled, allows custom per-target "env" properties to be used in transformers.
|
|
216
|
+
*
|
|
217
|
+
* @author Marcin Szczepanski <mszczepanski@atlassian.com>
|
|
167
218
|
*/
|
|
168
219
|
customEnvInTargets: process.env.ATLASPACK_BUILD_ENV === 'test',
|
|
169
220
|
/**
|
|
170
221
|
* When enabled, ensures the `unstableSingleFileOutput` environment property is preserved during CSS transformation
|
|
222
|
+
*
|
|
223
|
+
* @author Marcin Szczepanski <mszczepanski@atlassian.com>
|
|
171
224
|
*/
|
|
172
225
|
preserveUnstableSingleFileOutputInCss: process.env.ATLASPACK_BUILD_ENV === 'test',
|
|
226
|
+
/**
|
|
227
|
+
* When enabled, fixes handling of symbol locations when source maps contain
|
|
228
|
+
* project relative paths
|
|
229
|
+
*
|
|
230
|
+
* @author Matt Jones <mjones4@atlassian.com>
|
|
231
|
+
*/
|
|
232
|
+
symbolLocationFix: process.env.ATLASPACK_BUILD_ENV === 'test',
|
|
173
233
|
};
|
|
174
234
|
let featureFlagValues = { ...exports.DEFAULT_FEATURE_FLAGS };
|
|
175
235
|
function setFeatureFlags(flags) {
|
package/lib/index.js
CHANGED
|
@@ -17,24 +17,34 @@ const DEFAULT_FEATURE_FLAGS = exports.DEFAULT_FEATURE_FLAGS = {
|
|
|
17
17
|
exampleConsistencyCheckFeature: 'OLD',
|
|
18
18
|
/**
|
|
19
19
|
* Rust backed requests
|
|
20
|
+
*
|
|
21
|
+
* @author Matt Jones <mjones4@atlassian.com>
|
|
20
22
|
*/
|
|
21
23
|
atlaspackV3: false,
|
|
22
24
|
/**
|
|
23
25
|
* Use node.js implementation of @parcel/watcher watchman backend
|
|
26
|
+
*
|
|
27
|
+
* @author Pedro Tacla Yamada <pyamada@atlassian.com>
|
|
24
28
|
*/
|
|
25
29
|
useWatchmanWatcher: false,
|
|
26
30
|
/**
|
|
27
31
|
* Configure runtime to enable retriable dynamic imports
|
|
32
|
+
*
|
|
33
|
+
* @author David Alsh <dalsh@atlassian.com>
|
|
28
34
|
*/
|
|
29
35
|
importRetry: false,
|
|
30
36
|
/**
|
|
31
37
|
* Fixes quadratic cache invalidation issue
|
|
38
|
+
*
|
|
39
|
+
* @author Pedro Tacla Yamada <pyamada@atlassian.com>
|
|
32
40
|
*/
|
|
33
41
|
fixQuadraticCacheInvalidation: 'OLD',
|
|
34
42
|
/**
|
|
35
43
|
* Enables an experimental "conditional bundling" API - this allows the use of `importCond` syntax
|
|
36
44
|
* in order to have (consumer) feature flag driven bundling. This feature is very experimental,
|
|
37
45
|
* and requires server-side support.
|
|
46
|
+
*
|
|
47
|
+
* @author Jake Lane <jlane2@atlassian.com>
|
|
38
48
|
*/
|
|
39
49
|
conditionalBundlingApi: false,
|
|
40
50
|
/**
|
|
@@ -42,6 +52,8 @@ const DEFAULT_FEATURE_FLAGS = exports.DEFAULT_FEATURE_FLAGS = {
|
|
|
42
52
|
* - OLD - default value, return watchman result
|
|
43
53
|
* - NEW_AND_CHECK - Return VCS result but still call watchman
|
|
44
54
|
* - NEW: Return VCS result, but don't call watchman
|
|
55
|
+
*
|
|
56
|
+
* @author Celeste Carloni <ccarloni@atlassian.com>
|
|
45
57
|
*/
|
|
46
58
|
vcsMode: 'OLD',
|
|
47
59
|
/**
|
|
@@ -49,126 +61,174 @@ const DEFAULT_FEATURE_FLAGS = exports.DEFAULT_FEATURE_FLAGS = {
|
|
|
49
61
|
* - Split writes into multiple entries
|
|
50
62
|
* - Remove "large file blob" writes
|
|
51
63
|
* - Reduce size of the caches by deduplicating data
|
|
64
|
+
*
|
|
65
|
+
* @author Pedro Tacla Yamada <pyamada@atlassian.com>
|
|
52
66
|
*/
|
|
53
67
|
cachePerformanceImprovements: process.env.ATLASPACK_BUILD_ENV === 'test',
|
|
54
68
|
/**
|
|
55
69
|
* Deduplicates environments across cache / memory entities
|
|
70
|
+
*
|
|
71
|
+
* @author Pedro Tacla Yamada <pyamada@atlassian.com>
|
|
56
72
|
*/
|
|
57
73
|
environmentDeduplication: false,
|
|
58
74
|
/**
|
|
59
75
|
* Enable scanning for the presence of loadable to determine side effects
|
|
76
|
+
*
|
|
77
|
+
* @author Ben Jervis <bjervis@atlassian.com>
|
|
60
78
|
*/
|
|
61
79
|
loadableSideEffects: false,
|
|
62
80
|
/**
|
|
63
81
|
* Enable performance optimization for the resolver specifier to_string
|
|
64
82
|
* conversions
|
|
83
|
+
*
|
|
84
|
+
* @author Pedro Tacla Yamada <pyamada@atlassian.com>
|
|
65
85
|
*/
|
|
66
86
|
reduceResolverStringCreation: false,
|
|
67
87
|
/**
|
|
68
88
|
* Add verbose metrics for request tracker invalidation.
|
|
69
89
|
* Default to true as it's a monitoring change. Can be turned off if necessary.
|
|
90
|
+
*
|
|
91
|
+
* @author Pedro Tacla Yamada <pyamada@atlassian.com>
|
|
70
92
|
*/
|
|
71
93
|
verboseRequestInvalidationStats: true,
|
|
72
94
|
/**
|
|
73
95
|
* Fixes source maps for inline bundles
|
|
96
|
+
*
|
|
97
|
+
* @author Pedro Tacla Yamada <pyamada@atlassian.com>
|
|
74
98
|
*/
|
|
75
99
|
inlineBundlesSourceMapFixes: false,
|
|
76
100
|
/** Enable patch project paths. This will patch the project paths to be relative to the project root.
|
|
77
101
|
* This feature is experimental and should not be used in production. It will used to test downloadble cache artefacts.
|
|
102
|
+
*
|
|
103
|
+
* @author Celeste Carloni <ccarloni@atlassian.com>
|
|
78
104
|
*/
|
|
79
105
|
patchProjectPaths: false,
|
|
80
106
|
/**
|
|
81
107
|
* Enables optimized inline string replacement perf for the packager.
|
|
82
108
|
* Used heavily for inline bundles.
|
|
109
|
+
*
|
|
110
|
+
* @author Matt Jones <mjones4@atlassian.com>
|
|
83
111
|
*/
|
|
84
112
|
inlineStringReplacementPerf: false,
|
|
85
113
|
/**
|
|
86
114
|
* Enable resolution of bundler config starting from the CWD
|
|
115
|
+
*
|
|
116
|
+
* @author Ben Jervis <bjervis@atlassian.com>
|
|
87
117
|
*/
|
|
88
118
|
resolveBundlerConfigFromCwd: false,
|
|
89
119
|
/**
|
|
90
120
|
* Enable a setting that allows for more assets to be scope hoisted, if
|
|
91
121
|
* they're safe to do so.
|
|
122
|
+
*
|
|
123
|
+
* @author Ben Jervis <bjervis@atlassian.com>
|
|
92
124
|
*/
|
|
93
125
|
applyScopeHoistingImprovement: false,
|
|
94
126
|
/**
|
|
95
127
|
* Enable a change where a constant module only have the namespacing object added in bundles where it is required
|
|
128
|
+
*
|
|
129
|
+
* @author Marcin Szczepanski <mszczepanski@atlassian.com>
|
|
96
130
|
*/
|
|
97
131
|
inlineConstOptimisationFix: false,
|
|
98
132
|
/**
|
|
99
133
|
* Improves/fixes HMR behaviour by:
|
|
100
134
|
* - Fixing HMR behaviour with lazy bundle edges
|
|
101
135
|
* - Moving the functionality of the react-refresh runtime into the react-refresh-wrap transformer
|
|
136
|
+
*
|
|
137
|
+
* @author Marcin Szczepanski <mszczepanski@atlassian.com>
|
|
102
138
|
*/
|
|
103
139
|
hmrImprovements: false,
|
|
104
|
-
/**
|
|
105
|
-
* Fixes a bug where imported objects that are accessed with non-static
|
|
106
|
-
* properties (e.g. `CONSTANTS['api_' + endpoint`]) would not be recognised as
|
|
107
|
-
* being used, and thus not included in the bundle.
|
|
108
|
-
*/
|
|
109
|
-
unusedComputedPropertyFix: process.env.ATLASPACK_BUILD_ENV === 'test',
|
|
110
|
-
/**
|
|
111
|
-
* Fixes an issue where star re-exports of empty files (usually occurring in compiled typescript libraries)
|
|
112
|
-
* could cause exports to undefined at runtime.
|
|
113
|
-
*/
|
|
114
|
-
emptyFileStarRexportFix: process.env.ATLASPACK_BUILD_ENV === 'test',
|
|
115
140
|
/**
|
|
116
141
|
* Enables the new packaging progress CLI experience
|
|
142
|
+
*
|
|
143
|
+
* @author Matt Jones <mjones4@atlassian.com>
|
|
117
144
|
*/
|
|
118
145
|
cliProgressReportingImprovements: false,
|
|
119
146
|
/**
|
|
120
147
|
* Adds support for `webpackChunkName` comments in dynamic imports.
|
|
121
148
|
* Imports with the same `webpackChunkName` will be bundled together.
|
|
149
|
+
*
|
|
150
|
+
* @author Ben Jervis <bjervis@atlassian.com>
|
|
122
151
|
*/
|
|
123
152
|
supportWebpackChunkName: process.env.ATLASPACK_BUILD_ENV === 'test',
|
|
124
153
|
/**
|
|
125
154
|
* Enable a change to the conditional bundling loader to use a fallback bundle loading if the expected scripts aren't found
|
|
126
155
|
*
|
|
127
156
|
* Split into two flags, to allow usage in the dev or prod packagers separately
|
|
157
|
+
*
|
|
158
|
+
* @author Jake Lane <jlane2@atlassian.com>
|
|
128
159
|
*/
|
|
129
160
|
condbDevFallbackDev: false,
|
|
161
|
+
/**
|
|
162
|
+
*
|
|
163
|
+
* @author Jake Lane <jlane2@atlassian.com>
|
|
164
|
+
*/
|
|
130
165
|
condbDevFallbackProd: false,
|
|
131
166
|
/**
|
|
132
167
|
* Enable the new incremental bundling versioning logic which determines whether
|
|
133
168
|
* a full bundling pass is required based on the AssetGraph's bundlingVersion.
|
|
169
|
+
*
|
|
170
|
+
* @author Pedro Tacla Yamada <pyamada@atlassian.com>
|
|
134
171
|
*/
|
|
135
172
|
incrementalBundlingVersioning: process.env.ATLASPACK_BUILD_ENV === 'test',
|
|
136
173
|
/**
|
|
137
174
|
* Remove redundant shared bundles that are no longer required after merging
|
|
138
175
|
* async bundles.
|
|
176
|
+
*
|
|
177
|
+
* @author Matt Jones <mjones4@atlassian.com>
|
|
139
178
|
*/
|
|
140
179
|
removeRedundantSharedBundles: process.env.ATLASPACK_BUILD_ENV === 'test',
|
|
141
180
|
/**
|
|
142
181
|
* When enabled, single file output bundles have a stable name
|
|
182
|
+
*
|
|
183
|
+
* @author Marcin Szczepanski <mszczepanski@atlassian.com>
|
|
143
184
|
*/
|
|
144
185
|
singleFileOutputStableName: process.env.ATLASPACK_BUILD_ENV === 'test',
|
|
145
186
|
/**
|
|
146
187
|
* Enable optimised prelude for the ScopeHoistingPackager.
|
|
188
|
+
*
|
|
189
|
+
* @author Jake Lane <jlane2@atlassian.com>
|
|
147
190
|
*/
|
|
148
191
|
useNewPrelude: false,
|
|
149
192
|
/**
|
|
150
193
|
* Enable a fix for applyScopeHoistingImprovement that allows assets to still
|
|
151
194
|
* be at the top level of the bundle.
|
|
195
|
+
*
|
|
196
|
+
* @author Ben Jervis <bjervis@atlassian.com>
|
|
152
197
|
*/
|
|
153
198
|
applyScopeHoistingImprovementV2: false,
|
|
154
199
|
/**
|
|
155
200
|
* When enabled, if both explicit entries and explicit targets are specified,
|
|
156
201
|
* the source properties of those targets are used as filters against the base entries.
|
|
157
202
|
* This allows building only specific entries for specific targets.
|
|
203
|
+
*
|
|
204
|
+
* @author Marcin Szczepanski <mszczepanski@atlassian.com>
|
|
158
205
|
*/
|
|
159
206
|
allowExplicitTargetEntries: process.env.ATLASPACK_BUILD_ENV === 'test',
|
|
160
207
|
/**
|
|
161
208
|
* When enabled, the packager will avoid using the binding helper for exports where possible.
|
|
209
|
+
*
|
|
210
|
+
* @author Jake Lane <jlane2@atlassian.com>
|
|
162
211
|
*/
|
|
163
212
|
exportsRebindingOptimisation: false,
|
|
164
213
|
/**
|
|
165
214
|
* When enabled, allows custom per-target "env" properties to be used in transformers.
|
|
215
|
+
*
|
|
216
|
+
* @author Marcin Szczepanski <mszczepanski@atlassian.com>
|
|
166
217
|
*/
|
|
167
218
|
customEnvInTargets: process.env.ATLASPACK_BUILD_ENV === 'test',
|
|
168
219
|
/**
|
|
169
220
|
* When enabled, ensures the `unstableSingleFileOutput` environment property is preserved during CSS transformation
|
|
221
|
+
*
|
|
222
|
+
* @author Marcin Szczepanski <mszczepanski@atlassian.com>
|
|
223
|
+
*/
|
|
224
|
+
preserveUnstableSingleFileOutputInCss: process.env.ATLASPACK_BUILD_ENV === 'test',
|
|
225
|
+
/**
|
|
226
|
+
* When enabled, fixes handling of symbol locations when source maps contain
|
|
227
|
+
* project relative paths
|
|
228
|
+
*
|
|
229
|
+
* @author Matt Jones <mjones4@atlassian.com>
|
|
170
230
|
*/
|
|
171
|
-
|
|
231
|
+
symbolLocationFix: process.env.ATLASPACK_BUILD_ENV === 'test'
|
|
172
232
|
};
|
|
173
233
|
let featureFlagValues = {
|
|
174
234
|
...DEFAULT_FEATURE_FLAGS
|