lib/nodes.js
function Node(type, parent) {
  this.type = type;
  this.parent = parent;
  this.root = parent ? parent.root : this;
  this.identifyer = parent ? (++parent.root._counter) : 0;

  // The specific constructor will set another value if necessary
  this._textLength = 0;

  this.tags = 0;
  this.density = -1;

  this.children = [];

  this._text = '';
  this._textCompiled = false;
  this._noneStyleText = '';
  this._noneStyleTextCompiled = false;

  this.blocky = false;
  this.blockyChildren = false;

  this.inTree = true;
}
function Node(type, parent) {
  this.type = type;
  this.parent = parent;
  this.root = parent ? parent.root : this;
  this.identifyer = parent ? (++parent.root._counter) : 0;

  // The specific constructor will set another value if necessary
  this._textLength = 0;

  this.tags = 0;
  this.density = -1;

  this.children = [];

  this._text = '';
  this._textCompiled = false;
  this._noneStyleText = '';
  this._noneStyleTextCompiled = false;

  this.blocky = false;
  this.blockyChildren = false;

  this.inTree = true;
}
function Node ( type , parent ) { this . type = type ; this . parent = parent ; this . root = parent ? parent . root : this ; this . identifyer = parent ? ( ++ parent . root . _counter ) : 0 ; // The specific constructor will set another value if necessary this . _textLength = 0 ; this . tags = 0 ; this . density = - 1 ; this . children = [ ] ; this . _text = '' ; this . _textCompiled = false ; this . _noneStyleText = '' ; this . _noneStyleTextCompiled = false ; this . blocky = false ; this . blockyChildren = false ; this . inTree = true ; }
Node General abstaction between all node types The rule is that this should contain the most obviouse implementation
Node General abstaction between all node types The rule is that this should contain the most obviouse implementation