nl_tokens: Prepend the given element before the first existing element of same type . This is generally used for loading Docma assets first ( such as docma - web . js and docma . css ) . Update : this is NOT used for scripts anymore bec . jQuery 2 . x duplicates the scripts . For scripts we use our HtmlParser . DOM . insertBeforefirst () method instead . @private
pl_tokens: function _insertBeforeFirst ( $container , selector , elem ) { const foundElems = $container . find ( selector ) ; if ( foundElems . length > 0 ) { foundElems . eq ( 0 ) . before ( elem ) ; } else { $container . <mask> ( elem ) ; } }