@travetto/schema 7.0.0 → 7.0.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/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@travetto/schema",
|
|
3
|
-
"version": "7.0.
|
|
3
|
+
"version": "7.0.2",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "Data type registry for runtime validation, reflection and binding.",
|
|
6
6
|
"keywords": [
|
|
@@ -28,10 +28,10 @@
|
|
|
28
28
|
"directory": "module/schema"
|
|
29
29
|
},
|
|
30
30
|
"dependencies": {
|
|
31
|
-
"@travetto/registry": "^7.0.
|
|
31
|
+
"@travetto/registry": "^7.0.2"
|
|
32
32
|
},
|
|
33
33
|
"peerDependencies": {
|
|
34
|
-
"@travetto/transformer": "^7.0.
|
|
34
|
+
"@travetto/transformer": "^7.0.2"
|
|
35
35
|
},
|
|
36
36
|
"peerDependenciesMeta": {
|
|
37
37
|
"@travetto/transformer": {
|
|
@@ -2,7 +2,7 @@ import ts from 'typescript';
|
|
|
2
2
|
|
|
3
3
|
import {
|
|
4
4
|
TransformerState, OnProperty, OnClass, AfterClass, DocUtil, DeclarationUtil,
|
|
5
|
-
OnGetter, OnSetter, OnMethod, DecoratorUtil, OnStaticMethod
|
|
5
|
+
OnGetter, OnSetter, OnMethod, DecoratorUtil, OnStaticMethod
|
|
6
6
|
} from '@travetto/transformer';
|
|
7
7
|
|
|
8
8
|
import { SchemaTransformUtil } from './transformer/util.ts';
|
|
@@ -67,7 +67,7 @@ export class SchemaTransformer {
|
|
|
67
67
|
for (const item of state.getDecoratorList(node)) {
|
|
68
68
|
if (item.targets?.includes('@travetto/schema:Schema')) {
|
|
69
69
|
state[IsOptIn] ||= item.options?.includes('opt-in') ?? false;
|
|
70
|
-
const methodEnrolls = item.options?.filter(
|
|
70
|
+
const methodEnrolls = item.options?.filter(option => option.startsWith('method:'))?.map(option => option.replace('method:', '')) ?? [];
|
|
71
71
|
for (const method of methodEnrolls) {
|
|
72
72
|
state[AutoEnrollMethods].add(method);
|
|
73
73
|
}
|