vendor/html-css-sanitizer-bundle.js
function makeSaxParser(handler) {
    // Accept quoted or unquoted keys (Closure compat)
    var hcopy = {
      cdata: handler.cdata || handler['cdata'],
      comment: handler.comment || handler['comment'],
      endDoc: handler.endDoc || handler['endDoc'],
      endTag: handler.endTag || handler['endTag'],
      pcdata: handler.pcdata || handler['pcdata'],
      rcdata: handler.rcdata || handler['rcdata'],
      startDoc: handler.startDoc || handler['startDoc'],
      startTag: handler.startTag || handler['startTag']
    };
    return function(htmlText, param) {
      return parse(htmlText, hcopy, param);
    };
  }
function makeSaxParser(handler) {
    // Accept quoted or unquoted keys (Closure compat)
    var hcopy = {
      cdata: handler.cdata || handler['cdata'],
      comment: handler.comment || handler['comment'],
      endDoc: handler.endDoc || handler['endDoc'],
      endTag: handler.endTag || handler['endTag'],
      pcdata: handler.pcdata || handler['pcdata'],
      rcdata: handler.rcdata || handler['rcdata'],
      startDoc: handler.startDoc || handler['startDoc'],
      startTag: handler.startTag || handler['startTag']
    };
    return function(htmlText, param) {
      return parse(htmlText, hcopy, param);
    };
  }
function makeSaxParser ( handler ) { // Accept quoted or unquoted keys (Closure compat) var hcopy = { cdata : handler . cdata || handler [ 'cdata' ] , comment : handler . comment || handler [ 'comment' ] , endDoc : handler . endDoc || handler [ 'endDoc' ] , endTag : handler . endTag || handler [ 'endTag' ] , pcdata : handler . pcdata || handler [ 'pcdata' ] , rcdata : handler . rcdata || handler [ 'rcdata' ] , startDoc : handler . startDoc || handler [ 'startDoc' ] , startTag : handler . startTag || handler [ 'startTag' ] } ; return function ( htmlText , param ) { return parse ( htmlText , hcopy , param ) ; } ; }
Given a SAX-like event handler, produce a function that feeds those
events and a parameter to the event handler.

The event handler has the form:{@code
{
// Name is an upper-case HTML tag name.  Attribs is an array of
// alternating upper-case attribute names, and attribute values.  The
// attribs array is reused by the parser.  Param is the value passed to
// the saxParser.
startTag: function (name, attribs, param) { ... },
endTag:   function (name, param) { ... },
pcdata:   function (text, param) { ... },
rcdata:   function (text, param) { ... },
cdata:    function (text, param) { ... },
startDoc: function (param) { ... },
endDoc:   function (param) { ... }
}}

@param {Object} handler a record containing event handlers.
@return {function(string, Object)} A function that takes a chunk of HTML
and a parameter.  The parameter is passed on to the handler methods.
Given a SAX - like event handler produce a function that feeds those events and a parameter to the event handler .