UNPKG

ecmarkup

Version:

Custom element definitions and core utilities for markup that specifies ECMAScript and related technologies.

16 lines (12 loc) 376 B
module.exports = NonTerminal; function NonTerminal(spec, prod, node) { this.spec = spec; this.production = prod; this.node = node; this.params = node.getAttribute('params'); this.optional = node.hasAttribute('optional'); } NonTerminal.prototype.build = function() { var mods = this.production.createModifiersNode(this); this.node.insertBefore(mods, null); };