@colyseus/schema 4.0.14 → 4.0.16
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/build/codegen/cli.cjs +7 -3
- package/build/codegen/cli.cjs.map +1 -1
- package/build/index.cjs +19 -2
- package/build/index.cjs.map +1 -1
- package/build/index.js +19 -2
- package/build/index.mjs +19 -2
- package/build/index.mjs.map +1 -1
- package/package.json +1 -1
- package/src/codegen/parser.ts +8 -5
- package/src/encoder/StateView.ts +21 -4
package/build/codegen/cli.cjs
CHANGED
|
@@ -271,9 +271,13 @@ function inspectNode(node, context, decoratorName) {
|
|
|
271
271
|
break;
|
|
272
272
|
case ts__namespace.SyntaxKind.PropertySignature:
|
|
273
273
|
if (currentStructure instanceof Interface) {
|
|
274
|
-
const
|
|
275
|
-
|
|
276
|
-
|
|
274
|
+
const parent = node.parent;
|
|
275
|
+
// Only process direct children of InterfaceDeclaration, skip TypeLiterals
|
|
276
|
+
if (!ts__namespace.isInterfaceDeclaration(parent)) {
|
|
277
|
+
break;
|
|
278
|
+
}
|
|
279
|
+
// Skip if property if for a another interface than the one we're interested in.
|
|
280
|
+
if (currentStructure.name !== parent.name.escapedText.toString()) {
|
|
277
281
|
break;
|
|
278
282
|
}
|
|
279
283
|
// define a property of an interface
|