ts-graphviz
    Preparing search index...

    Function renderHTMLLike

    • Converts a React element into a custom HTML-like string representation.

      If no label is provided, returns the string '<>'. Otherwise, renders the React element to static markup, transforms any dot:-prefixed tags by removing the prefix, and wraps the result in angle brackets.

      Parameters

      • Optionallabel: ReactElement<unknown, string | JSXElementConstructor<any>>

        Optional React element to render.

      • Optionaloptions: RenderHTMLLikeOptions

        Optional rendering options.

      Returns string

      A string representing the transformed HTML-like markup.

      // Default behavior (max depth: 1000)
      renderHTMLLike(<div><span>Hello</span></div>);

      // Custom max depth for deeply nested structures
      renderHTMLLike(<div>...</div>, { maxDepth: 5000 });

      // Lower max depth for strict validation
      renderHTMLLike(<div>...</div>, { maxDepth: 100 });