gatherStyles(template) {
    const styleText = gatherStyleText(template.content);
    if (styleText) {
      const style = /** @type {!HTMLStyleElement} */(document.createElement('style'));
      style.textContent = styleText;
      template.content.insertBefore(style, template.content.firstChild);
      return style;
    }
    return null;
  }
/**
   * Gather styles into one style for easier processing
   * @param {!HTMLTemplateElement} template
   * @return {HTMLStyleElement}
   */
Gather styles into one style for easier processing
@param {!HTMLTemplateElement} template
@return {HTMLStyleElement}
Gather styles into one style for easier processing @param { !HTMLTemplateElement } template @return { HTMLStyleElement }
gatherStyles(template) {
    const styleText = gatherStyleText(template.content);
    if (styleText) {
      const style = (document.createElement('style'));
      style.textContent = styleText;
      template.content.insertBefore(style, template.content.firstChild);
      return style;
    }
    return null;
  }
gatherStyles ( template ) { const styleText = gatherStyleText ( template . content ) ; if ( styleText ) { const style = ( document . createElement ( 'style' ) ) ; style . textContent = styleText ; template . content . insertBefore ( style , template . content . firstChild ) ; return style ; } return null ; }
Gather styles into one style for easier processing
 @param {!HTMLTemplateElement} template
 @return {HTMLStyleElement}
Gather styles into one style for easier processing @param { !HTMLTemplateElement } template @return { HTMLStyleElement }
/** @type {!HTMLStyleElement} */