code: function prepareTemplate(element) {
  
    let template = element[symbols.template];
  
    if (!template) {
      /* eslint-disable no-console */
      console.warn(`ShadowTemplateMixin expects ${element.constructor.name} to define a property called [symbols.template].\nSee https://elix.org/documentation/ShadowTemplateMixin.`);
      return;
    }
  
    if (!(template instanceof HTMLTemplateElement)) {
      throw `Warning: the [symbols.template] property for ${element.constructor.name} must return an HTMLTemplateElement.`;
    }
  
    // @ts-ignore
    if (window.ShadyCSS && !window.ShadyCSS.nativeShadow) {
      // Let the CSS polyfill do its own initialization.
      const tag = element.localName;
      // @ts-ignore
      window.ShadyCSS.prepareTemplate(template, tag);
    }
  
    return template;
  }
docs: Retrieve an element's template and prepare it for use.