@jsenv/core 38.3.11 → 38.4.1
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 +17 -18
- package/dist/babel_helpers/AsyncGenerator/AsyncGenerator.js +3 -3
- package/dist/babel_helpers/AwaitValue/AwaitValue.js +2 -2
- package/dist/babel_helpers/{overloadYield/overloadYield.js → OverloadYield/OverloadYield.js} +1 -1
- package/dist/babel_helpers/applyDecoratedDescriptor/applyDecoratedDescriptor.js +23 -14
- package/dist/babel_helpers/applyDecs/applyDecs.js +32 -21
- package/dist/babel_helpers/applyDecs2203/applyDecs2203.js +549 -549
- package/dist/babel_helpers/applyDecs2203R/applyDecs2203R.js +27 -15
- package/dist/babel_helpers/applyDecs2301/applyDecs2301.js +29 -18
- package/dist/babel_helpers/applyDecs2305/applyDecs2305.js +362 -541
- package/dist/babel_helpers/arrayLikeToArray/arrayLikeToArray.js +4 -4
- package/dist/babel_helpers/arrayWithHoles/arrayWithHoles.js +2 -2
- package/dist/babel_helpers/arrayWithoutHoles/arrayWithoutHoles.js +3 -3
- package/dist/babel_helpers/assertThisInitialized/assertThisInitialized.js +5 -3
- package/dist/babel_helpers/asyncGeneratorDelegate/asyncGeneratorDelegate.js +2 -2
- package/dist/babel_helpers/asyncIterator/asyncIterator.js +1 -1
- package/dist/babel_helpers/asyncToGenerator/asyncToGenerator.js +17 -17
- package/dist/babel_helpers/awaitAsyncGenerator/awaitAsyncGenerator.js +2 -2
- package/dist/babel_helpers/callSuper/callSuper.js +25 -0
- package/dist/babel_helpers/checkInRHS/checkInRHS.js +10 -8
- package/dist/babel_helpers/classApplyDescriptorDestructureSet/classApplyDescriptorDestructureSet.js +9 -6
- package/dist/babel_helpers/classApplyDescriptorGet/classApplyDescriptorGet.js +2 -2
- package/dist/babel_helpers/classApplyDescriptorSet/classApplyDescriptorSet.js +3 -3
- package/dist/babel_helpers/classCallCheck/classCallCheck.js +1 -1
- package/dist/babel_helpers/classCheckPrivateStaticAccess/classCheckPrivateStaticAccess.js +5 -2
- package/dist/babel_helpers/classCheckPrivateStaticFieldDescriptor/classCheckPrivateStaticFieldDescriptor.js +7 -2
- package/dist/babel_helpers/classExtractFieldDescriptor/classExtractFieldDescriptor.js +9 -3
- package/dist/babel_helpers/classNameTDZError/classNameTDZError.js +3 -1
- package/dist/babel_helpers/classPrivateFieldDestructureSet/classPrivateFieldDestructureSet.js +4 -4
- package/dist/babel_helpers/classPrivateFieldGet/classPrivateFieldGet.js +4 -4
- package/dist/babel_helpers/classPrivateFieldLooseBase/classPrivateFieldLooseBase.js +2 -2
- package/dist/babel_helpers/classPrivateFieldLooseKey/classPrivateFieldLooseKey.js +2 -2
- package/dist/babel_helpers/classPrivateFieldSet/classPrivateFieldSet.js +5 -5
- package/dist/babel_helpers/classPrivateMethodGet/classPrivateMethodGet.js +2 -2
- package/dist/babel_helpers/classPrivateMethodSet/classPrivateMethodSet.js +1 -1
- package/dist/babel_helpers/classStaticPrivateFieldSpecGet/classStaticPrivateFieldSpecGet.js +11 -7
- package/dist/babel_helpers/classStaticPrivateFieldSpecSet/classStaticPrivateFieldSpecSet.js +7 -7
- package/dist/babel_helpers/classStaticPrivateMethodGet/classStaticPrivateMethodGet.js +8 -4
- package/dist/babel_helpers/classStaticPrivateMethodSet/classStaticPrivateMethodSet.js +1 -1
- package/dist/babel_helpers/construct/construct.js +18 -14
- package/dist/babel_helpers/createClass/createClass.js +1 -1
- package/dist/babel_helpers/createForOfIteratorHelper/createForOfIteratorHelper.js +21 -20
- package/dist/babel_helpers/createForOfIteratorHelperLoose/createForOfIteratorHelperLoose.js +10 -9
- package/dist/babel_helpers/createRawReactElement/createRawReactElement.js +11 -11
- package/dist/babel_helpers/createSuper/createSuper.js +11 -11
- package/dist/babel_helpers/decorate/decorate.js +255 -170
- package/dist/babel_helpers/defaults/defaults.js +5 -5
- package/dist/babel_helpers/defineAccessor/defineAccessor.js +1 -1
- package/dist/babel_helpers/defineEnumerableProperties/defineEnumerableProperties.js +11 -11
- package/dist/babel_helpers/defineProperty/defineProperty.js +4 -4
- package/dist/babel_helpers/dispose/dispose.js +39 -39
- package/dist/babel_helpers/extends/extends.js +4 -4
- package/dist/babel_helpers/get/get.js +2 -2
- package/dist/babel_helpers/getPrototypeOf/getPrototypeOf.js +1 -1
- package/dist/babel_helpers/identity/identity.js +1 -1
- package/dist/babel_helpers/importDeferProxy/importDeferProxy.js +27 -27
- package/dist/babel_helpers/inherits/inherits.js +4 -4
- package/dist/babel_helpers/inheritsLoose/inheritsLoose.js +4 -4
- package/dist/babel_helpers/initializerDefineProperty/initializerDefineProperty.js +5 -3
- package/dist/babel_helpers/initializerWarningHelper/initializerWarningHelper.js +1 -1
- package/dist/babel_helpers/instanceof/instanceof.js +7 -3
- package/dist/babel_helpers/interopRequireDefault/interopRequireDefault.js +1 -1
- package/dist/babel_helpers/interopRequireWildcard/interopRequireWildcard.js +3 -1
- package/dist/babel_helpers/isNativeFunction/isNativeFunction.js +1 -1
- package/dist/babel_helpers/isNativeReflectConstruct/isNativeReflectConstruct.js +12 -14
- package/dist/babel_helpers/iterableToArray/iterableToArray.js +1 -1
- package/dist/babel_helpers/iterableToArrayLimit/iterableToArrayLimit.js +1 -1
- package/dist/babel_helpers/iterableToArrayLimitLoose/iterableToArrayLimitLoose.js +1 -1
- package/dist/babel_helpers/jsx/jsx.js +1 -1
- package/dist/babel_helpers/maybeArrayLike/maybeArrayLike.js +4 -4
- package/dist/babel_helpers/newArrowCheck/newArrowCheck.js +1 -1
- package/dist/babel_helpers/nonIterableRest/nonIterableRest.js +2 -2
- package/dist/babel_helpers/nonIterableSpread/nonIterableSpread.js +2 -2
- package/dist/babel_helpers/nullishReceiverError/nullishReceiverError.js +1 -1
- package/dist/babel_helpers/objectDestructuringEmpty/objectDestructuringEmpty.js +1 -1
- package/dist/babel_helpers/objectSpread/objectSpread.js +8 -8
- package/dist/babel_helpers/objectSpread2/objectSpread2.js +5 -3
- package/dist/babel_helpers/objectWithoutProperties/objectWithoutProperties.js +12 -12
- package/dist/babel_helpers/objectWithoutPropertiesLoose/objectWithoutPropertiesLoose.js +10 -10
- package/dist/babel_helpers/possibleConstructorReturn/possibleConstructorReturn.js +7 -5
- package/dist/babel_helpers/readOnlyError/readOnlyError.js +1 -1
- package/dist/babel_helpers/regeneratorRuntime/regeneratorRuntime.js +1 -1
- package/dist/babel_helpers/set/set.js +22 -19
- package/dist/babel_helpers/setFunctionName/setFunctionName.js +18 -0
- package/dist/babel_helpers/setPrototypeOf/setPrototypeOf.js +7 -6
- package/dist/babel_helpers/skipFirstGeneratorNext/skipFirstGeneratorNext.js +4 -4
- package/dist/babel_helpers/slicedToArray/slicedToArray.js +5 -5
- package/dist/babel_helpers/slicedToArrayLoose/slicedToArrayLoose.js +5 -5
- package/dist/babel_helpers/superPropBase/superPropBase.js +4 -4
- package/dist/babel_helpers/taggedTemplateLiteral/taggedTemplateLiteral.js +2 -2
- package/dist/babel_helpers/taggedTemplateLiteralLoose/taggedTemplateLiteralLoose.js +3 -3
- package/dist/babel_helpers/tdz/tdz.js +1 -1
- package/dist/babel_helpers/temporalRef/temporalRef.js +3 -3
- package/dist/babel_helpers/toArray/toArray.js +5 -5
- package/dist/babel_helpers/toConsumableArray/toConsumableArray.js +5 -5
- package/dist/babel_helpers/toPrimitive/toPrimitive.js +11 -7
- package/dist/babel_helpers/toPropertyKey/toPropertyKey.js +8 -4
- package/dist/babel_helpers/typeof/typeof.js +6 -5
- package/dist/babel_helpers/unsupportedIterableToArray/unsupportedIterableToArray.js +7 -7
- package/dist/babel_helpers/using/using.js +20 -20
- package/dist/babel_helpers/wrapAsyncGenerator/wrapAsyncGenerator.js +3 -3
- package/dist/babel_helpers/wrapNativeSuper/wrapNativeSuper.js +12 -12
- package/dist/babel_helpers/wrapRegExp/wrapRegExp.js +5 -3
- package/dist/babel_helpers/writeOnlyError/writeOnlyError.js +1 -1
- package/dist/js/ribbon.js +1 -1
- package/dist/js/ws.js +234 -146
- package/dist/jsenv_core.js +1365 -1211
- package/package.json +26 -22
- package/src/build/build.js +22 -14
- package/src/dev/start_dev_server.js +8 -21
- package/src/kitchen/errors.js +29 -24
- package/src/kitchen/kitchen.js +1 -1
- package/src/kitchen/url_graph/references.js +8 -0
- package/src/kitchen/url_graph/url_graph_report.js +5 -3
- package/src/plugins/plugins.js +2 -2
- package/src/plugins/protocol_file/jsenv_plugin_protocol_file.js +17 -7
- package/src/plugins/reference_analysis/js/jsenv_plugin_js_reference_analysis.js +10 -12
- package/src/plugins/ribbon/client/ribbon.js +1 -1
package/README.md
CHANGED
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
# @jsenv/core [](https://www.npmjs.com/package/@jsenv/core)
|
|
2
2
|
|
|
3
|
-
Jsenv is a tool to develop test and build projects using JavaScript.
|
|
3
|
+
Jsenv is a tool to develop test and build projects using JavaScript.
|
|
4
|
+
It favors standards and simplicity.
|
|
4
5
|
|
|
5
|
-
|
|
6
|
+
As a result it can be enjoyed by people without much experience in tooling or seeking for a simple tool without hidden complexities.
|
|
6
7
|
|
|
7
|
-
|
|
8
|
-
2. A build generating an optimized version of source files into a directory
|
|
9
|
-
3. A build server serving build files
|
|
10
|
-
4. A test runner executing test files in web browser(s)
|
|
8
|
+
The core tools provided by jsenv:
|
|
11
9
|
|
|
12
|
-
|
|
13
|
-
|
|
10
|
+
1. **dev server**; a server for source files
|
|
11
|
+
2. **build**; generate an optimized version of source files into a directory
|
|
12
|
+
3. **build server**; a server for build files
|
|
13
|
+
4. **test runner**; execute all test files at once
|
|
14
14
|
|
|
15
15
|
[Link to documentation](<https://github.com/jsenv/core/wiki/A)-directory-structure>)
|
|
16
16
|
|
|
@@ -18,19 +18,18 @@ As a result it can be enjoyed by people without much experience in tooling or se
|
|
|
18
18
|
|
|
19
19
|
- Test files are [executed like standard files](<https://github.com/jsenv/core/wiki/D)-Test#14-executing-a-single-test>)
|
|
20
20
|
- [Isolated environment](<https://github.com/jsenv/core/wiki/D)-Test#33-isolated-environment>) for each test file
|
|
21
|
-
-
|
|
22
|
-
-
|
|
23
|
-
-
|
|
24
|
-
-
|
|
21
|
+
- Execute [tests in multiple browsers](<https://github.com/jsenv/core/wiki/D)-Test#32-execute-on-more-browsers>): Chrome, Safari, Firefox
|
|
22
|
+
- [Large browser support during dev](<https://github.com/jsenv/core/wiki/B)-Dev#21-browser-support>). Because some people might be happy to use an other browser than the latest chrome during dev. Moreover it is useful to reproduce bug specific to certain browsers.
|
|
23
|
+
- [Large browser support after build](<https://github.com/jsenv/core/wiki/C)-Build#211-maximal-browser-support>). Because some product still needs to support old versions of Firefox, Chrome and Safari.
|
|
24
|
+
- [Single set of files after build](<https://github.com/jsenv/core/wiki/C)-Build#212-same-build-for-all-browsers>). Because a single one is simpler to properly support in every aspects.
|
|
25
25
|
- Versioning during build is robust and <a href="https://bundlers.tooling.report/hashing/avoid-cascade/" target="_blank">avoids cascading hash changes</a><sup>↗</sup>
|
|
26
|
-
-
|
|
27
|
-
-
|
|
26
|
+
- Advanced support of top level await, allowing to use it everywhere
|
|
27
|
+
- Advanced support of web workers including worker type module
|
|
28
28
|
- Unlock js module features on a regular `<script>` when needed. If you need the behaviour of `<script>` which is to block execution of following `<script>` in the page, you'll be happy to [still have the power of js modules](<https://github.com/jsenv/core/wiki/G)-Plugins#22-asjsclassic>), like imports, at your disposal.
|
|
29
29
|
|
|
30
30
|
# Demos
|
|
31
31
|
|
|
32
|
-
A demo is a project pre-configured with jsenv.
|
|
33
|
-
|
|
32
|
+
A demo is a project pre-configured with jsenv.
|
|
34
33
|
The following command can be used to install and try a demo:
|
|
35
34
|
|
|
36
35
|
```console
|
|
@@ -65,9 +64,9 @@ After running the suggested commands the demo is ready.
|
|
|
65
64
|
The demo contains preconfigured scripts:
|
|
66
65
|
|
|
67
66
|
- `npm run dev`: starts a server for source files; Documented in [B) Dev](<https://github.com/jsenv/core/wiki/B)-Dev>).
|
|
68
|
-
- `npm run build`: generate files
|
|
67
|
+
- `npm run build`: generate build files; Documented in [C) Build](<https://github.com/jsenv/core/wiki/C)-Build>).
|
|
69
68
|
- `npm run build:serve`: start a server for build files; Documented in [C) Build#how-to-serve-build-files](<https://github.com/jsenv/core/wiki/C)-Build#3-how-to-serve-build-files>).
|
|
70
|
-
- `npm run test`: execute test files
|
|
69
|
+
- `npm run test`: execute test files; Documented in [D) Test](<https://github.com/jsenv/core/wiki/D)-Test>).
|
|
71
70
|
|
|
72
71
|
<!--
|
|
73
72
|
The following commands can be used to skip the prompt
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/* @minVersion 7.0.0-beta.0 */
|
|
2
2
|
|
|
3
|
-
import OverloadYield from "../
|
|
3
|
+
import OverloadYield from "../OverloadYield/OverloadYield.js";
|
|
4
4
|
|
|
5
5
|
export default function AsyncGenerator(gen) {
|
|
6
6
|
var front, back;
|
|
@@ -59,7 +59,7 @@ export default function AsyncGenerator(gen) {
|
|
|
59
59
|
},
|
|
60
60
|
function (err) {
|
|
61
61
|
resume("throw", err);
|
|
62
|
-
}
|
|
62
|
+
},
|
|
63
63
|
);
|
|
64
64
|
} catch (err) {
|
|
65
65
|
settle("throw", err);
|
|
@@ -109,4 +109,4 @@ AsyncGenerator.prototype.throw = function (arg) {
|
|
|
109
109
|
};
|
|
110
110
|
AsyncGenerator.prototype.return = function (arg) {
|
|
111
111
|
return this._invoke("return", arg);
|
|
112
|
-
};
|
|
112
|
+
};
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export default function _AwaitValue
|
|
2
|
-
this.wrapped = value
|
|
1
|
+
export default function _AwaitValue(value) {
|
|
2
|
+
this.wrapped = value;
|
|
3
3
|
}
|
|
@@ -1,23 +1,32 @@
|
|
|
1
|
-
export default function _applyDecoratedDescriptor(
|
|
1
|
+
export default function _applyDecoratedDescriptor(
|
|
2
|
+
target,
|
|
3
|
+
property,
|
|
4
|
+
decorators,
|
|
5
|
+
descriptor,
|
|
6
|
+
context,
|
|
7
|
+
) {
|
|
2
8
|
var desc = {};
|
|
3
|
-
Object.keys(descriptor).forEach(function(key){
|
|
4
|
-
|
|
9
|
+
Object.keys(descriptor).forEach(function (key) {
|
|
10
|
+
desc[key] = descriptor[key];
|
|
5
11
|
});
|
|
6
12
|
desc.enumerable = !!desc.enumerable;
|
|
7
13
|
desc.configurable = !!desc.configurable;
|
|
8
|
-
if (
|
|
9
|
-
|
|
14
|
+
if ("value" in desc || desc.initializer) {
|
|
15
|
+
desc.writable = true;
|
|
10
16
|
}
|
|
11
|
-
desc = decorators
|
|
17
|
+
desc = decorators
|
|
18
|
+
.slice()
|
|
19
|
+
.reverse()
|
|
20
|
+
.reduce(function (desc, decorator) {
|
|
12
21
|
return decorator(target, property, desc) || desc;
|
|
13
|
-
|
|
14
|
-
if (context && desc.initializer !== void 0){
|
|
15
|
-
|
|
16
|
-
|
|
22
|
+
}, desc);
|
|
23
|
+
if (context && desc.initializer !== void 0) {
|
|
24
|
+
desc.value = desc.initializer ? desc.initializer.call(context) : void 0;
|
|
25
|
+
desc.initializer = undefined;
|
|
17
26
|
}
|
|
18
|
-
if (desc.initializer === void 0){
|
|
19
|
-
|
|
20
|
-
|
|
27
|
+
if (desc.initializer === void 0) {
|
|
28
|
+
Object.defineProperty(target, property, desc);
|
|
29
|
+
desc = null;
|
|
21
30
|
}
|
|
22
31
|
return desc;
|
|
23
|
-
}
|
|
32
|
+
}
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
/* @minVersion 7.17.8 */
|
|
2
2
|
|
|
3
|
+
import setFunctionName from "../setFunctionName/setFunctionName.js";
|
|
4
|
+
import toPropertyKey from "../toPropertyKey/toPropertyKey.js";
|
|
3
5
|
/**
|
|
4
6
|
* NOTE: This is an old version of the helper, used for 2021-12 decorators.
|
|
5
7
|
* Updates should be done in applyDecs2203R.js.
|
|
@@ -27,7 +29,7 @@ function old_createMetadataMethodsForProperty(
|
|
|
27
29
|
metadataMap,
|
|
28
30
|
kind,
|
|
29
31
|
property,
|
|
30
|
-
decoratorFinishedRef
|
|
32
|
+
decoratorFinishedRef,
|
|
31
33
|
) {
|
|
32
34
|
return {
|
|
33
35
|
getMetadata: function (key) {
|
|
@@ -145,7 +147,7 @@ function old_memberDec(
|
|
|
145
147
|
kind,
|
|
146
148
|
isStatic,
|
|
147
149
|
isPrivate,
|
|
148
|
-
value
|
|
150
|
+
value,
|
|
149
151
|
) {
|
|
150
152
|
var kindStr;
|
|
151
153
|
|
|
@@ -168,7 +170,7 @@ function old_memberDec(
|
|
|
168
170
|
|
|
169
171
|
var ctx = {
|
|
170
172
|
kind: kindStr,
|
|
171
|
-
name: isPrivate ? "#" + name : name,
|
|
173
|
+
name: isPrivate ? "#" + name : toPropertyKey(name),
|
|
172
174
|
isStatic: isStatic,
|
|
173
175
|
isPrivate: isPrivate,
|
|
174
176
|
};
|
|
@@ -178,7 +180,7 @@ function old_memberDec(
|
|
|
178
180
|
if (kind !== 0 /* FIELD */) {
|
|
179
181
|
ctx.addInitializer = old_createAddInitializerMethod(
|
|
180
182
|
initializers,
|
|
181
|
-
decoratorFinishedRef
|
|
183
|
+
decoratorFinishedRef,
|
|
182
184
|
);
|
|
183
185
|
}
|
|
184
186
|
|
|
@@ -227,9 +229,9 @@ function old_memberDec(
|
|
|
227
229
|
metadataMap,
|
|
228
230
|
metadataKind,
|
|
229
231
|
metadataName,
|
|
230
|
-
decoratorFinishedRef
|
|
231
|
-
)
|
|
232
|
-
)
|
|
232
|
+
decoratorFinishedRef,
|
|
233
|
+
),
|
|
234
|
+
),
|
|
233
235
|
);
|
|
234
236
|
} finally {
|
|
235
237
|
decoratorFinishedRef.v = true;
|
|
@@ -239,7 +241,7 @@ function old_memberDec(
|
|
|
239
241
|
function old_assertNotFinished(decoratorFinishedRef, fnName) {
|
|
240
242
|
if (decoratorFinishedRef.v) {
|
|
241
243
|
throw new Error(
|
|
242
|
-
"attempted to call " + fnName + " after decoration was finished"
|
|
244
|
+
"attempted to call " + fnName + " after decoration was finished",
|
|
243
245
|
);
|
|
244
246
|
}
|
|
245
247
|
}
|
|
@@ -262,7 +264,7 @@ function old_assertValidReturnValue(kind, value) {
|
|
|
262
264
|
if (kind === 1 /* ACCESSOR */) {
|
|
263
265
|
if (type !== "object" || value === null) {
|
|
264
266
|
throw new TypeError(
|
|
265
|
-
"accessor decorators must return an object with get, set, or init properties or void 0"
|
|
267
|
+
"accessor decorators must return an object with get, set, or init properties or void 0",
|
|
266
268
|
);
|
|
267
269
|
}
|
|
268
270
|
if (value.get !== undefined) {
|
|
@@ -311,11 +313,11 @@ function old_applyMemberDec(
|
|
|
311
313
|
isStatic,
|
|
312
314
|
isPrivate,
|
|
313
315
|
metadataMap,
|
|
314
|
-
initializers
|
|
316
|
+
initializers,
|
|
315
317
|
) {
|
|
316
318
|
var decs = decInfo[0];
|
|
317
319
|
|
|
318
|
-
var desc, initializer, value;
|
|
320
|
+
var desc, initializer, prefix, value;
|
|
319
321
|
|
|
320
322
|
if (isPrivate) {
|
|
321
323
|
if (kind === 0 /* FIELD */ || kind === 1 /* ACCESSOR */) {
|
|
@@ -323,19 +325,28 @@ function old_applyMemberDec(
|
|
|
323
325
|
get: decInfo[3],
|
|
324
326
|
set: decInfo[4],
|
|
325
327
|
};
|
|
328
|
+
prefix = "get";
|
|
326
329
|
} else if (kind === 3 /* GETTER */) {
|
|
327
330
|
desc = {
|
|
328
331
|
get: decInfo[3],
|
|
329
332
|
};
|
|
333
|
+
prefix = "get";
|
|
330
334
|
} else if (kind === 4 /* SETTER */) {
|
|
331
335
|
desc = {
|
|
332
336
|
set: decInfo[3],
|
|
333
337
|
};
|
|
338
|
+
prefix = "set";
|
|
334
339
|
} else {
|
|
335
340
|
desc = {
|
|
336
341
|
value: decInfo[3],
|
|
337
342
|
};
|
|
338
343
|
}
|
|
344
|
+
if (kind !== 0 /* FIELD */) {
|
|
345
|
+
if (kind === 1 /* ACCESSOR */) {
|
|
346
|
+
setFunctionName(decInfo[4], "#" + name, "set");
|
|
347
|
+
}
|
|
348
|
+
setFunctionName(decInfo[3], "#" + name, prefix);
|
|
349
|
+
}
|
|
339
350
|
} else if (kind !== 0 /* FIELD */) {
|
|
340
351
|
desc = Object.getOwnPropertyDescriptor(base, name);
|
|
341
352
|
}
|
|
@@ -365,7 +376,7 @@ function old_applyMemberDec(
|
|
|
365
376
|
kind,
|
|
366
377
|
isStatic,
|
|
367
378
|
isPrivate,
|
|
368
|
-
value
|
|
379
|
+
value,
|
|
369
380
|
);
|
|
370
381
|
|
|
371
382
|
if (newValue !== void 0) {
|
|
@@ -396,7 +407,7 @@ function old_applyMemberDec(
|
|
|
396
407
|
kind,
|
|
397
408
|
isStatic,
|
|
398
409
|
isPrivate,
|
|
399
|
-
value
|
|
410
|
+
value,
|
|
400
411
|
);
|
|
401
412
|
|
|
402
413
|
if (newValue !== void 0) {
|
|
@@ -495,7 +506,7 @@ function old_applyMemberDecs(
|
|
|
495
506
|
Class,
|
|
496
507
|
protoMetadataMap,
|
|
497
508
|
staticMetadataMap,
|
|
498
|
-
decInfos
|
|
509
|
+
decInfos,
|
|
499
510
|
) {
|
|
500
511
|
var protoInitializers;
|
|
501
512
|
var staticInitializers;
|
|
@@ -551,7 +562,7 @@ function old_applyMemberDecs(
|
|
|
551
562
|
) {
|
|
552
563
|
throw new Error(
|
|
553
564
|
"Attempted to decorate a public method/accessor that has the same name as a previously decorated public method/accessor. This is not currently supported by the decorators plugin. Property name was: " +
|
|
554
|
-
name
|
|
565
|
+
name,
|
|
555
566
|
);
|
|
556
567
|
} else if (!existingKind && kind > 2 /* METHOD */) {
|
|
557
568
|
existingNonFields.set(name, kind);
|
|
@@ -569,7 +580,7 @@ function old_applyMemberDecs(
|
|
|
569
580
|
isStatic,
|
|
570
581
|
isPrivate,
|
|
571
582
|
metadataMap,
|
|
572
|
-
initializers
|
|
583
|
+
initializers,
|
|
573
584
|
);
|
|
574
585
|
}
|
|
575
586
|
|
|
@@ -604,15 +615,15 @@ function old_applyClassDecs(ret, targetClass, metadataMap, classDecs) {
|
|
|
604
615
|
name: name,
|
|
605
616
|
addInitializer: old_createAddInitializerMethod(
|
|
606
617
|
initializers,
|
|
607
|
-
decoratorFinishedRef
|
|
618
|
+
decoratorFinishedRef,
|
|
608
619
|
),
|
|
609
620
|
},
|
|
610
621
|
old_createMetadataMethodsForProperty(
|
|
611
622
|
metadataMap,
|
|
612
623
|
0 /* CONSTRUCTOR */,
|
|
613
624
|
name,
|
|
614
|
-
decoratorFinishedRef
|
|
615
|
-
)
|
|
625
|
+
decoratorFinishedRef,
|
|
626
|
+
),
|
|
616
627
|
);
|
|
617
628
|
var nextNewClass = classDecs[i](newClass, ctx);
|
|
618
629
|
} finally {
|
|
@@ -789,7 +800,7 @@ export default function applyDecs(targetClass, memberDecs, classDecs) {
|
|
|
789
800
|
targetClass,
|
|
790
801
|
protoMetadataMap,
|
|
791
802
|
staticMetadataMap,
|
|
792
|
-
memberDecs
|
|
803
|
+
memberDecs,
|
|
793
804
|
);
|
|
794
805
|
|
|
795
806
|
old_convertMetadataMapToFinal(targetClass.prototype, protoMetadataMap);
|
|
@@ -799,4 +810,4 @@ export default function applyDecs(targetClass, memberDecs, classDecs) {
|
|
|
799
810
|
old_convertMetadataMapToFinal(targetClass, staticMetadataMap);
|
|
800
811
|
|
|
801
812
|
return ret;
|
|
802
|
-
}
|
|
813
|
+
}
|