[{"data":1,"prerenderedAt":562},["ShallowReactive",2],{"content-en-\u002Fsyntax\u002Ftoc":3},{"id":4,"title":5,"body":6,"description":554,"extension":555,"jsonLd":556,"meta":557,"navigation":362,"path":558,"schemaRole":556,"seo":559,"stem":560,"__hash__":561},"content_en\u002Fsyntax\u002Ftoc.md","TOC helper",{"type":7,"value":8,"toc":542},"minimark",[9,13,35,40,43,60,94,103,106,115,119,181,185,243,251,256,259,291,295,309,313,340,344,347,399,402,501,505,538],[10,11,5],"h1",{"id":12},"toc-helper",[14,15,16,17,21,22,26,27,30,31,34],"p",{},"Insert a ",[18,19,20],"strong",{},"Markdown table of contents"," built from the document’s headings. Place ",[23,24,25],"code",{},"toc"," or ",[23,28,29],{},"toc(N)"," where you want the list — hyogen expands it after includes, layouts, control flow, and ",[23,32,33],{},"{{ }}"," evaluation.",[36,37,39],"h2",{"id":38},"syntax","Syntax",[14,41,42],{},"These forms are equivalent:",[44,45,50],"pre",{"className":46,"code":47,"language":48,"meta":49,"style":49},"language-markdown shiki shiki-themes github-dark-high-contrast","\u003C!--@@ toc(3) @@-->\n","markdown","",[23,51,52],{"__ignoreMap":49},[53,54,57],"span",{"class":55,"line":56},"line",1,[53,58,47],{"class":59},"sQrFR",[44,61,63],{"className":46,"code":62,"language":48,"meta":49,"style":49},"\u003C!--\n@hg\ntoc(3)\n@endhg\n-->\n",[23,64,65,70,76,82,88],{"__ignoreMap":49},[53,66,67],{"class":55,"line":56},[53,68,69],{"class":59},"\u003C!--\n",[53,71,73],{"class":55,"line":72},2,[53,74,75],{"class":59},"@hg\n",[53,77,79],{"class":55,"line":78},3,[53,80,81],{"class":59},"toc(3)\n",[53,83,85],{"class":55,"line":84},4,[53,86,87],{"class":59},"@endhg\n",[53,89,91],{"class":55,"line":90},5,[53,92,93],{"class":59},"-->\n",[44,95,97],{"className":46,"code":96,"language":48,"meta":49,"style":49},"\u003C!--@hg toc(3) @endhg-->\n",[23,98,99],{"__ignoreMap":49},[53,100,101],{"class":55,"line":56},[53,102,96],{"class":59},[14,104,105],{},"Omit the argument to include all heading levels (h1–h6):",[44,107,109],{"className":46,"code":108,"language":48,"meta":49,"style":49},"\u003C!--@@ toc @@-->\n",[23,110,111],{"__ignoreMap":49},[53,112,113],{"class":55,"line":56},[53,114,108],{"class":59},[36,116,118],{"id":117},"argument","Argument",[120,121,122,135],"table",{},[123,124,125],"thead",{},[126,127,128,132],"tr",{},[129,130,131],"th",{},"Item",[129,133,134],{},"Detail",[136,137,138,157,165],"tbody",{},[126,139,140,146],{},[141,142,143],"td",{},[23,144,145],{},"N",[141,147,148,149,152,153,156],{},"Integer ",[18,150,151],{},"1–6"," — maximum heading level (e.g. ",[23,154,155],{},"toc(3)"," → h1–h3)",[126,158,159,162],{},[141,160,161],{},"Omitted",[141,163,164],{},"All levels through h6",[126,166,167,170],{},[141,168,169],{},"Invalid",[141,171,172,173,176,177,180],{},"Error — stops render (negative, decimal, ",[23,174,175],{},"0",", ",[23,178,179],{},"7+",", non-numeric)",[36,182,184],{"id":183},"what-headings-are-included","What headings are included",[186,187,188,214,219],"ul",{},[189,190,191,194,195,198,199,202,203,194,206,209,210,213],"li",{},[18,192,193],{},"ATX"," (",[23,196,197],{},"#"," … ",[23,200,201],{},"######",") and ",[18,204,205],{},"Setext",[23,207,208],{},"==="," \u002F ",[23,211,212],{},"---",") headings",[189,215,216,217],{},"Only levels within the max level ",[23,218,145],{},[189,220,221,222,225,226,209,229,209,232,209,235,209,238,209,241],{},"Source is the ",[18,223,224],{},"final Markdown"," after ",[23,227,228],{},"include",[23,230,231],{},"extend",[23,233,234],{},"component",[23,236,237],{},"if",[23,239,240],{},"each",[23,242,33],{},[14,244,245,246,209,248,250],{},"Headings that disappear under ",[23,247,237],{},[23,249,240],{}," are not listed. Multiple TOC directives on one page each generate a full TOC independently.",[252,253,255],"h3",{"id":254},"excluded-regions","Excluded regions",[14,257,258],{},"Headings inside these regions are ignored:",[186,260,261,271,285],{},[189,262,263,264,209,267,270],{},"Fenced code blocks (",[23,265,266],{},"```",[23,268,269],{},"~~~",")",[189,272,273,274,198,277,209,280,198,283,270],{},"Hyogen blocks (",[23,275,276],{},"@hg",[23,278,279],{},"@endhg",[23,281,282],{},"@@",[23,284,282],{},[189,286,287,288,270],{},"HTML comments (",[23,289,290],{},"\u003C!-- … -->",[36,292,294],{"id":293},"output","Output",[186,296,297,303,306],{},[189,298,299,300],{},"Nested Markdown list with anchor links: ",[23,301,302],{},"[text](#anchor)",[189,304,305],{},"Heading text is plain (Markdown emphasis markers stripped)",[189,307,308],{},"No matching headings → empty string (no warning)",[252,310,312],{"id":311},"anchor-ids","Anchor IDs",[314,315,316,326],"ol",{},[189,317,318,319,322,323],{},"Explicit ID wins: ",[23,320,321],{},"## Title {#my-id}"," → ",[23,324,325],{},"#my-id",[189,327,328,329,332,333,176,336,339],{},"Otherwise ",[18,330,331],{},"GitHub-compatible"," slug (lowercase, spaces → hyphens, punctuation stripped; duplicates get ",[23,334,335],{},"-1",[23,337,338],{},"-2",", …)",[36,341,343],{"id":342},"example","Example",[14,345,346],{},"Input:",[44,348,350],{"className":46,"code":349,"language":48,"meta":49,"style":49},"# Page Title\n\n\u003C!--@@ toc(3) @@-->\n\n## Section A\n\n### Sub A-1\n\n## Section B\n",[23,351,352,358,364,368,372,377,382,388,393],{"__ignoreMap":49},[53,353,354],{"class":55,"line":56},[53,355,357],{"class":356},"s-VM4","# Page Title\n",[53,359,360],{"class":55,"line":72},[53,361,363],{"emptyLinePlaceholder":362},true,"\n",[53,365,366],{"class":55,"line":78},[53,367,47],{"class":59},[53,369,370],{"class":55,"line":84},[53,371,363],{"emptyLinePlaceholder":362},[53,373,374],{"class":55,"line":90},[53,375,376],{"class":356},"## Section A\n",[53,378,380],{"class":55,"line":379},6,[53,381,363],{"emptyLinePlaceholder":362},[53,383,385],{"class":55,"line":384},7,[53,386,387],{"class":356},"### Sub A-1\n",[53,389,391],{"class":55,"line":390},8,[53,392,363],{"emptyLinePlaceholder":362},[53,394,396],{"class":55,"line":395},9,[53,397,398],{"class":356},"## Section B\n",[14,400,401],{},"Output (excerpt):",[44,403,405],{"className":46,"code":404,"language":48,"meta":49,"style":49},"# Page Title\n\n- [Page Title](#page-title)\n- [Section A](#section-a)\n  - [Sub A-1](#sub-a-1)\n- [Section B](#section-b)\n\n## Section A\n...\n",[23,406,407,411,415,439,455,472,488,492,496],{"__ignoreMap":49},[53,408,409],{"class":55,"line":56},[53,410,357],{"class":356},[53,412,413],{"class":55,"line":72},[53,414,363],{"emptyLinePlaceholder":362},[53,416,417,421,425,429,432,436],{"class":55,"line":78},[53,418,420],{"class":419},"s_sBn","-",[53,422,424],{"class":423},"sMAXC"," [",[53,426,428],{"class":427},"sTRMh","Page Title",[53,430,431],{"class":423},"](",[53,433,435],{"class":434},"sajvY","#page-title",[53,437,438],{"class":423},")\n",[53,440,441,443,445,448,450,453],{"class":55,"line":84},[53,442,420],{"class":419},[53,444,424],{"class":423},[53,446,447],{"class":427},"Section A",[53,449,431],{"class":423},[53,451,452],{"class":434},"#section-a",[53,454,438],{"class":423},[53,456,457,460,462,465,467,470],{"class":55,"line":90},[53,458,459],{"class":419},"  -",[53,461,424],{"class":423},[53,463,464],{"class":427},"Sub A-1",[53,466,431],{"class":423},[53,468,469],{"class":434},"#sub-a-1",[53,471,438],{"class":423},[53,473,474,476,478,481,483,486],{"class":55,"line":379},[53,475,420],{"class":419},[53,477,424],{"class":423},[53,479,480],{"class":427},"Section B",[53,482,431],{"class":423},[53,484,485],{"class":434},"#section-b",[53,487,438],{"class":423},[53,489,490],{"class":55,"line":384},[53,491,363],{"emptyLinePlaceholder":362},[53,493,494],{"class":55,"line":390},[53,495,376],{"class":356},[53,497,498],{"class":55,"line":395},[53,499,500],{"class":423},"...\n",[36,502,504],{"id":503},"related","Related",[186,506,507,520,527],{},[189,508,509,514,515,209,517,519],{},[510,511,513],"a",{"href":512},"\u002Fen\u002Fsyntax\u002Fhg-blocks","Hyogen blocks"," — ",[23,516,276],{},[23,518,282],{}," forms",[189,521,522,526],{},[510,523,525],{"href":524},"\u002Fen\u002Fsyntax\u002Fincludes","Includes and components"," — headings from included content",[189,528,529,514,533,209,535,537],{},[510,530,532],{"href":531},"\u002Fen\u002Fsyntax\u002Fcontrol-flow","Control flow",[23,534,237],{},[23,536,240],{}," affect which headings remain",[539,540,541],"style",{},"html pre.shiki code .sQrFR, html code.shiki .sQrFR{--shiki-default:#BDC4CC}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html pre.shiki code .s-VM4, html code.shiki .s-VM4{--shiki-default:#91CBFF;--shiki-default-font-weight:bold}html pre.shiki code .s_sBn, html code.shiki .s_sBn{--shiki-default:#FFB757}html pre.shiki code .sMAXC, html code.shiki .sMAXC{--shiki-default:#F0F3F6}html pre.shiki code .sTRMh, html code.shiki .sTRMh{--shiki-default:#ADDCFF}html pre.shiki code .sajvY, html code.shiki .sajvY{--shiki-default:#F0F3F6;--shiki-default-text-decoration:underline}",{"title":49,"searchDepth":72,"depth":72,"links":543},[544,545,546,549,552,553],{"id":38,"depth":72,"text":39},{"id":117,"depth":72,"text":118},{"id":183,"depth":72,"text":184,"children":547},[548],{"id":254,"depth":78,"text":255},{"id":293,"depth":72,"text":294,"children":550},[551],{"id":311,"depth":78,"text":312},{"id":342,"depth":72,"text":343},{"id":503,"depth":72,"text":504},"Generate a Markdown table of contents from page headings with toc \u002F toc(N).","md",null,{},"\u002Fsyntax\u002Ftoc",{"title":5,"description":554},"syntax\u002Ftoc","LTyP2NdlWeLN17d499m4gk0iuLa-BuU_v-qvZzQaMnw",1788678618920]