code: def _as_html(plot_spec: Dict) -> str:
      """
      Creates plot HTML using 'html' frontend context.
  
      :param plot_spec: dict
      """
      if TEXT_HTML not in _frontend_contexts:
          if _use_isolated_frame():
              # 'Isolated' HTML context can be setup lazily.
              _setup_html_context(
                  isolated_frame=True,
                  offline=False,
                  no_js=False,
                  show_status=False,
              )
          else:
              return """\
                  <div style="color:darkred;">
                      Lets-plot `html` is not configured.<br> 
                      Try to use `LetsPlot.setup_html()` before first occurrence of plot.
                  </div>    
                  """
  
      return _frontend_contexts[TEXT_HTML].as_str(plot_spec)
  
file_path: lets-plot/python-package/lets_plot/frontend_context/_configuration.py
imports: from typing import Dict, Any
  from ._frontend_ctx import FrontendContext
  from ._html_contexts import _create_html_frontend_context, _use_isolated_frame
  from ._json_contexts import _create_json_frontend_context, _is_Intellij_Python_Lets_Plot_Plugin
  from ._mime_types import TEXT_HTML, LETS_PLOT_JSON
  from ._static_svg_ctx import StaticSvgImageContext
  from .._version import __version__
  from ..plot.core import PlotSpec
  from ..plot.plot import GGBunch
  from ..plot.subplots import SupPlotsSpec
label_desc: Use image node_id 3 for calling a global function with example usage: _as_html(plot_spec) and returns: _frontend_contexts, str