UNPKG

@zlooun/exceljs

Version:

Fixes the problem with writing a file using streams and not using RAM based on 'exeljs'

32 lines (24 loc) 489 B
const BaseXform = require('../base-xform'); class BooleanXform extends BaseXform { constructor(options) { super(); this.tag = options.tag; this.attr = options.attr; } render(xmlStream, model) { if (model) { xmlStream.openNode(this.tag); xmlStream.closeNode(); } } parseOpen(node) { if (node.name === this.tag) { this.model = true; } } parseText() {} parseClose() { return false; } } module.exports = BooleanXform;