code: def _load_js_resource(resource_type: _AxPlotJSResources) -> str:
      """Convert plot config to corresponding JS code."""
      resource = pkgutil.get_data(
          PLOT_MODULE_NAME,
          os.path.join("js", "common", resource_type.value + ".js"),
      )
      if resource is None:
          raise ValueError(
              f"Cannot find JS resource {resource_type.value}."
          )
      return resource.decode("utf8")
  
file_path: Ax/ax/plot/render.py
imports: import enum
  import json
  import os
  import pkgutil
  import uuid
  from typing import Dict
  import plotly.offline
  from ax.plot.base import AxPlotConfig, AxPlotTypes
  from jinja2 import Template
label_desc: Use image node_id 1 for calling a global function with example usage: _load_js_resource(resource_type) and returns: resource