{
  "id": "@typed/template#toHtml",
  "canonicalId": "@typed/template#toHtml",
  "symbol": {
    "id": "@typed/template#toHtml",
    "packageName": "@typed/template",
    "moduleName": ".",
    "exportName": "toHtml",
    "kind": "function",
    "signatures": [
      "export declare function toHtml(node: Rendered): string;"
    ],
    "summary": "Converts a `Rendered` value to an HTML string.",
    "sections": {
      "Why": "DOM integrations can expose a diagnostic/string representation while\npreserving their concrete nodes for DOM consumers.",
      "Ownership and lifetime": "Serialization reads the current DOM and neither moves nor retains nodes. It\nis not the streaming SSR renderer and does not sanitize existing markup."
    },
    "examples": [
      {
        "language": "ts",
        "code": "import { toHtml } from \"@typed/template/Wire\"\n\nconst div = document.createElement(\"div\")\ndiv.textContent = \"Hello\"\nconst html = toHtml(div) // \"<div>Hello</div>\"\n\nconst fragment = document.createDocumentFragment()\nfragment.appendChild(div)\nconst fragmentHtml = toHtml(fragment) // \"<div>Hello</div>\""
      }
    ],
    "relations": [],
    "source": {
      "file": "packages/template/src/Wire.ts",
      "line": 723
    },
    "since": "1.0.0",
    "category": "DOM serialization"
  },
  "exposure": {
    "recordKind": "declaration",
    "id": "@typed/template#toHtml",
    "packageName": "@typed/template",
    "packageVersion": "1.0.0-beta.13",
    "moduleName": ".",
    "consumerSpecifier": "@typed/template",
    "exportName": "toHtml",
    "qualifiedName": "toHtml",
    "declarationKey": "declaration:0343e60afe5c3fdbccea44c6",
    "family": "function",
    "signatures": [
      "export declare function toHtml(node: Rendered): string;"
    ],
    "sourceSpans": [
      {
        "file": "packages/template/src/Wire.ts",
        "start": {
          "line": 723,
          "column": 1
        },
        "end": {
          "line": 731,
          "column": 2
        }
      }
    ],
    "aliases": [
      "@typed/template/Wire#toHtml"
    ],
    "isAlias": false,
    "static": false
  },
  "declaration": {
    "declarationKey": "declaration:0343e60afe5c3fdbccea44c6",
    "name": "toHtml",
    "family": "function",
    "facets": [
      {
        "family": "function",
        "syntaxKind": "FunctionDeclaration",
        "signatures": [
          "export declare function toHtml(node: Rendered): string;"
        ],
        "typeParameters": [],
        "sourceSpans": [
          {
            "file": "packages/template/src/Wire.ts",
            "start": {
              "line": 723,
              "column": 1
            },
            "end": {
              "line": 731,
              "column": 2
            }
          }
        ],
        "static": false,
        "readonly": false,
        "optional": false
      }
    ],
    "signatures": [
      "export declare function toHtml(node: Rendered): string;"
    ],
    "typeParameters": [],
    "summary": "Converts a `Rendered` value to an HTML string.",
    "sections": {
      "Why": "DOM integrations can expose a diagnostic/string representation while\npreserving their concrete nodes for DOM consumers.",
      "Ownership and lifetime": "Serialization reads the current DOM and neither moves nor retains nodes. It\nis not the streaming SSR renderer and does not sanitize existing markup."
    },
    "examples": [
      {
        "language": "ts",
        "code": "import { toHtml } from \"@typed/template/Wire\"\n\nconst div = document.createElement(\"div\")\ndiv.textContent = \"Hello\"\nconst html = toHtml(div) // \"<div>Hello</div>\"\n\nconst fragment = document.createDocumentFragment()\nfragment.appendChild(div)\nconst fragmentHtml = toHtml(fragment) // \"<div>Hello</div>\""
      }
    ],
    "sourceSpans": [
      {
        "file": "packages/template/src/Wire.ts",
        "start": {
          "line": 723,
          "column": 1
        },
        "end": {
          "line": 731,
          "column": 2
        }
      }
    ],
    "since": "1.0.0",
    "category": "DOM serialization"
  }
}
