In type structure classes, consider replacing writerFunction with stringOrWriter
Closed this issue · 1 comments
ajvincent commented
For LiteralTypeStructureImpl
, NumberTypeStructureImpl
, and StringTypeStructureImpl
, it doesn't make sense to have writer functions. The last can do JSON.stringify(this.stringValue)
, and the others just return this.stringValue;
.
ajvincent commented
I didn't think this all the way through: typedWriter.stringOrWriter(writer)
looks terrible.