code: def write_class_file(
      name,
      props,
      description,
      project_shortname,
      prefix=None,
      rpkg_data=None,
  ):
      props = reorder_props(props=props)
  
      # generate the R help pages for each of the Dash components that we
      # are transpiling -- this is done to avoid using Roxygen2 syntax,
      # we may eventually be able to generate similar documentation using
      # doxygen and an R plugin, but for now we'll just do it on our own
      # from within Python
      write_help_file(name, props, description, prefix, rpkg_data)
  
      import_string = "# AUTO GENERATED FILE - DO NOT EDIT\n\n"
      class_string = generate_class_string(
          name, props, project_shortname, prefix
      )
  
      file_name = format_fn_name(prefix, name) + ".R"
  
      file_path = os.path.join("R", file_name)
      with open(file_path, "w", encoding="utf-8") as f:
          f.write(import_string)
          f.write(class_string)
  
      print("Generated {}".format(file_name))
  
imports: import os
  import sys
  import shutil
  import importlib
  import textwrap
  import re
  import warnings
  from ._all_keywords import r_keywords
  from ._py_components_generation import reorder_props
label_desc: Use image node_id 6 for calling a global function with example usage: write_class_file(name, props, description, project_shortname, prefix, rpkg_data) without return types