docs-navigation.ts 5.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154
  1. export type NavItem = {
  2. title: string;
  3. href: string;
  4. external?: boolean;
  5. };
  6. export type NavSection = {
  7. title: string;
  8. items: NavItem[];
  9. };
  10. export const docsNavigation: NavSection[] = [
  11. {
  12. title: "Getting Started",
  13. items: [
  14. { title: "Introduction", href: "/docs" },
  15. { title: "Installation", href: "/docs/installation" },
  16. { title: "Quick Start", href: "/docs/quick-start" },
  17. { title: "Skills", href: "/docs/skills" },
  18. { title: "Migration Guide", href: "/docs/migration" },
  19. { title: "Changelog", href: "/docs/changelog" },
  20. ],
  21. },
  22. {
  23. title: "Core",
  24. items: [
  25. { title: "Specs", href: "/docs/specs" },
  26. { title: "Schemas", href: "/docs/schemas" },
  27. { title: "Catalog", href: "/docs/catalog" },
  28. { title: "Data Binding", href: "/docs/data-binding" },
  29. { title: "Computed Values", href: "/docs/computed-values" },
  30. { title: "Visibility", href: "/docs/visibility" },
  31. { title: "Watchers", href: "/docs/watchers" },
  32. { title: "Validation", href: "/docs/validation" },
  33. ],
  34. },
  35. {
  36. title: "Rendering",
  37. items: [
  38. { title: "Renderers", href: "/docs/renderers" },
  39. { title: "Registry", href: "/docs/registry" },
  40. { title: "Streaming", href: "/docs/streaming" },
  41. { title: "Generation Modes", href: "/docs/generation-modes" },
  42. ],
  43. },
  44. {
  45. title: "Examples",
  46. items: [
  47. {
  48. title: "Chat",
  49. href: "https://github.com/vercel-labs/json-render/tree/main/examples/chat",
  50. external: true,
  51. },
  52. {
  53. title: "Dashboard",
  54. href: "https://github.com/vercel-labs/json-render/tree/main/examples/dashboard",
  55. external: true,
  56. },
  57. {
  58. title: "React Native",
  59. href: "https://github.com/vercel-labs/json-render/tree/main/examples/react-native",
  60. external: true,
  61. },
  62. {
  63. title: "React PDF",
  64. href: "https://github.com/vercel-labs/json-render/tree/main/examples/react-pdf",
  65. external: true,
  66. },
  67. {
  68. title: "React Email",
  69. href: "https://github.com/vercel-labs/json-render/tree/main/examples/react-email",
  70. external: true,
  71. },
  72. {
  73. title: "Remotion",
  74. href: "https://github.com/vercel-labs/json-render/tree/main/examples/remotion",
  75. external: true,
  76. },
  77. {
  78. title: "Image",
  79. href: "https://github.com/vercel-labs/json-render/tree/main/examples/image",
  80. external: true,
  81. },
  82. {
  83. title: "Svelte",
  84. href: "https://github.com/vercel-labs/json-render/tree/main/examples/svelte",
  85. external: true,
  86. },
  87. {
  88. title: "Vue",
  89. href: "https://github.com/vercel-labs/json-render/tree/main/examples/vue",
  90. external: true,
  91. },
  92. {
  93. title: "Renders with Vite (Vue / React / Svelte / Solid)",
  94. href: "https://github.com/vercel-labs/json-render/tree/main/examples/vite-renderers",
  95. external: true,
  96. },
  97. {
  98. title: "MCP App",
  99. href: "https://github.com/vercel-labs/json-render/tree/main/examples/mcp",
  100. external: true,
  101. },
  102. ],
  103. },
  104. {
  105. title: "Guides",
  106. items: [
  107. { title: "Custom Schema", href: "/docs/custom-schema" },
  108. { title: "Code Export", href: "/docs/code-export" },
  109. ],
  110. },
  111. {
  112. title: "Integrations",
  113. items: [
  114. { title: "AI SDK", href: "/docs/ai-sdk" },
  115. { title: "A2UI", href: "/docs/a2ui" },
  116. { title: "Adaptive Cards", href: "/docs/adaptive-cards" },
  117. { title: "AG-UI", href: "/docs/ag-ui" },
  118. { title: "OpenAPI", href: "/docs/openapi" },
  119. ],
  120. },
  121. {
  122. title: "API Reference",
  123. items: [
  124. { title: "@json-render/core", href: "/docs/api/core" },
  125. { title: "@json-render/react", href: "/docs/api/react" },
  126. { title: "@json-render/react-pdf", href: "/docs/api/react-pdf" },
  127. { title: "@json-render/react-email", href: "/docs/api/react-email" },
  128. { title: "@json-render/shadcn", href: "/docs/api/shadcn" },
  129. { title: "@json-render/react-native", href: "/docs/api/react-native" },
  130. { title: "@json-render/image", href: "/docs/api/image" },
  131. { title: "@json-render/remotion", href: "/docs/api/remotion" },
  132. { title: "@json-render/vue", href: "/docs/api/vue" },
  133. { title: "@json-render/svelte", href: "/docs/api/svelte" },
  134. { title: "@json-render/solid", href: "/docs/api/solid" },
  135. {
  136. title: "@json-render/react-three-fiber",
  137. href: "/docs/api/react-three-fiber",
  138. },
  139. { title: "@json-render/codegen", href: "/docs/api/codegen" },
  140. { title: "@json-render/mcp", href: "/docs/api/mcp" },
  141. { title: "@json-render/redux", href: "/docs/api/redux" },
  142. { title: "@json-render/zustand", href: "/docs/api/zustand" },
  143. { title: "@json-render/jotai", href: "/docs/api/jotai" },
  144. { title: "@json-render/xstate", href: "/docs/api/xstate" },
  145. ],
  146. },
  147. ];
  148. // Flatten all pages for current page lookup (excludes external links)
  149. export const allDocsPages = docsNavigation.flatMap((section) =>
  150. section.items.filter((item) => !item.external),
  151. );