_moveOrderedImperativesFromHeadIntoHiddenDiv(ast) {
        const head = dom5.query(ast, matchers.head);
        if (!head) {
            return;
        }
        const firstHtmlImport = dom5.query(head, matchers.eagerHtmlImport);
        if (!firstHtmlImport) {
            return;
        }
        for (const node of [firstHtmlImport].concat(astUtils.siblingsAfter(firstHtmlImport))) {
            if (matchers.orderedImperative(node)) {
                astUtils.removeElementAndNewline(node);
                dom5.append(this._findOrCreateHiddenDiv(ast), node);
            }
        }
    }
/**
     * When an HTML Import is encountered in the head of the document, it needs
     * to be moved into the hidden div and any subsequent order-dependent
     * imperatives (imports, styles, scripts) must also be move into the
     * hidden div.
     */
When an HTML Import is encountered in the head of the document, it needs
to be moved into the hidden div and any subsequent order-dependent
imperatives (imports, styles, scripts) must also be move into the
hidden div.
When an HTML Import is encountered in the head of the document it needs to be moved into the hidden div and any subsequent order - dependent imperatives ( imports styles scripts ) must also be move into the hidden div .
_moveOrderedImperativesFromHeadIntoHiddenDiv(ast) {
        const head = dom5.query(ast, matchers.head);
        if (!head) {
            return;
        }
        const firstHtmlImport = dom5.query(head, matchers.eagerHtmlImport);
        if (!firstHtmlImport) {
            return;
        }
        for (const node of [firstHtmlImport].concat(astUtils.siblingsAfter(firstHtmlImport))) {
            if (matchers.orderedImperative(node)) {
                astUtils.removeElementAndNewline(node);
                dom5.append(this._findOrCreateHiddenDiv(ast), node);
            }
        }
    }
_moveOrderedImperativesFromHeadIntoHiddenDiv ( ast ) { const head = dom5 . query ( ast , matchers . head ) ; if ( ! head ) { return ; } const firstHtmlImport = dom5 . query ( head , matchers . eagerHtmlImport ) ; if ( ! firstHtmlImport ) { return ; } for ( const node of [ firstHtmlImport ] . concat ( astUtils . siblingsAfter ( firstHtmlImport ) ) ) { if ( matchers . orderedImperative ( node ) ) { astUtils . removeElementAndNewline ( node ) ; dom5 . append ( this . _findOrCreateHiddenDiv ( ast ) , node ) ; } } }
When an HTML Import is encountered in the head of the document, it needs
 to be moved into the hidden div and any subsequent order-dependent
 imperatives (imports, styles, scripts) must also be move into the
 hidden div.
When an HTML Import is encountered in the head of the document it needs to be moved into the hidden div and any subsequent order - dependent imperatives ( imports styles scripts ) must also be move into the hidden div .