From d636fddd6c6df8664c9514123cca769a5d26a1fa Mon Sep 17 00:00:00 2001 From: Eugene Lubarsky Date: Tue, 9 Oct 2018 00:10:11 +1100 Subject: [PATCH] Added Emitter.emitShape API to enable the shape to be customised --- lib/emit.ts | 3 +++ 1 file changed, 3 insertions(+) diff --git a/lib/emit.ts b/lib/emit.ts index b251d27..f45bb30 100644 --- a/lib/emit.ts +++ b/lib/emit.ts @@ -75,6 +75,9 @@ export default class Emitter { } public emit(root: any, rootName: string): void { let rootShape = d2s(this, root); + this.emitShape(rootShape, rootName) + } + public emitShape(rootShape: Shape, rootName: string): void { if (rootShape.type === BaseShape.COLLECTION) { rootShape = rootShape.baseShape; }