diff --git a/data/sidebar_manual_v1200.json b/data/sidebar_manual_v1200.json index 516432f57..ce301d35f 100644 --- a/data/sidebar_manual_v1200.json +++ b/data/sidebar_manual_v1200.json @@ -2,9 +2,32 @@ "Overview": [ "introduction", "installation", - "migrate-to-v11", "editor-plugins", - "try" + "faq", + "llms" + ], + "Guides": [ + "converting-from-js", + "editor-code-analysis", + "newcomer-examples", + "project-structure" + ], + "JavaScript Interop": [ + "interop-cheatsheet", + "embed-raw-javascript", + "shared-data-types", + "external", + "bind-to-js-object", + "bind-to-js-function", + "import-from-export-to-js", + "bind-to-global-js-values", + "json", + "inlining-constants", + "use-illegal-identifier-names", + "generate-converters-accessors", + "browser-support-polyfills", + "libraries", + "typescript-integration" ], "Language Features": [ "overview", @@ -35,27 +58,6 @@ "reserved-keywords", "equality-comparison" ], - "Advanced Features": [ - "extensible-variant", - "scoped-polymorphic-types" - ], - "JavaScript Interop": [ - "interop-cheatsheet", - "embed-raw-javascript", - "shared-data-types", - "external", - "bind-to-js-object", - "bind-to-js-function", - "import-from-export-to-js", - "bind-to-global-js-values", - "json", - "inlining-constants", - "use-illegal-identifier-names", - "generate-converters-accessors", - "browser-support-polyfills", - "libraries", - "typescript-integration" - ], "Build System": [ "build-overview", "build-configuration", @@ -66,14 +68,8 @@ "build-performance", "warning-numbers" ], - "Guides": [ - "converting-from-js", - "editor-code-analysis" - ], - "Extra": [ - "newcomer-examples", - "project-structure", - "faq", - "llms" + "Advanced Features": [ + "extensible-variant", + "scoped-polymorphic-types" ] } \ No newline at end of file diff --git a/pages/docs/manual/v12.0.0/api.mdx b/pages/docs/manual/v12.0.0/api.mdx index 933480b1c..0fa1a42a2 100644 --- a/pages/docs/manual/v12.0.0/api.mdx +++ b/pages/docs/manual/v12.0.0/api.mdx @@ -10,9 +10,5 @@ In ReScript 11, it is shipped as a separate npm package `@rescript/core` that is ReScript ships with these two additional modules in its standard library: -- [Belt](api/belt): immutable collections and extra helpers not available in JavaScript / [Core](api/core). -- [Dom](api/dom): Dom related types and modules. Contains our standardized types used by various userland DOM bindings. - -## Legacy Modules - -The [Js](api/js) module is superseded by [Core](api/core). +- [Belt](api/belt): immutable collections and extra helpers not available in [Core](api/core). +- [Dom](api/dom): Dom related types and modules. Contains our standardized types used by various userland DOM bindings. \ No newline at end of file diff --git a/pages/docs/manual/v12.0.0/editor-code-analysis.mdx b/pages/docs/manual/v12.0.0/editor-code-analysis.mdx index eb4b7b612..cce661ff3 100644 --- a/pages/docs/manual/v12.0.0/editor-code-analysis.mdx +++ b/pages/docs/manual/v12.0.0/editor-code-analysis.mdx @@ -1,11 +1,11 @@ --- -title: "Editor" -metaTitle: "Editor" +title: "Dead Code Analysis in ReScript" +metaTitle: "Dead Code Analysis in ReScript" description: "Documentation about ReScript editor plugins and code analysis" canonical: "/docs/manual/v12.0.0/editor-plugins" --- -# Guide: Dead Code Analysis in ReScript +# Dead Code Analysis in ReScript This guide provides a detailed walkthrough on how to leverage ReScript’s powerful dead code analysis tools to maintain a clean, efficient, and distraction-free codebase. diff --git a/src/components/Navigation.res b/src/components/Navigation.res index d5aab3c41..fcecc0b19 100644 --- a/src/components/Navigation.res +++ b/src/components/Navigation.res @@ -16,6 +16,10 @@ let linkOrActiveApiSubroute = (~route) => { } } +let isActiveLink = (~route: string, ~href: string) => { + route == href ? activeLink : link +} + module CollapsibleLink = { // KeepOpen = Menu has been opened and should stay open type state = @@ -177,27 +181,6 @@ module DocsSection = { } }, }, - { - imgSrc: "/static/ic_gentype@2x.png", - title: "GenType", - description: "Seamless TypeScript integration", - href: `/docs/manual/${version}/typescript-integration`, - isActive: url => { - switch url.fullpath { - | ["docs", "manual", _, "typescript-integration"] => true - | _ => false - } - }, - }, - { - imgSrc: "/static/ic_reanalyze@2x.png", - title: "Reanalyze", - description: "Dead Code & Termination analysis", - href: "https://github.com/rescript-lang/reanalyze", - isActive: _ => { - false - }, - }, ] let languageManualColumn = @@ -532,10 +515,21 @@ let make = (~fixed=true, ~isOverlayOpen: bool, ~setOverlayOpen: (bool => bool) =
- {collapsibleElements->React.array} - + + {React.string("Docs")} + + {React.string("API")} + + {React.string("React")} + diff --git a/src/layouts/ApiOverviewLayout.res b/src/layouts/ApiOverviewLayout.res index df5a626f6..2688bb984 100644 --- a/src/layouts/ApiOverviewLayout.res +++ b/src/layouts/ApiOverviewLayout.res @@ -2,12 +2,12 @@ module Sidebar = SidebarLayout.Sidebar let makeCategories: string => array = version => [ { - name: "Introduction", - items: [{name: "Overview", href: `/docs/manual/${version}/api`}], - }, - { - name: "Standard Library", - items: [{name: "Core", href: `/docs/manual/${version}/api/core`}], + name: "", + items: [ + {name: "Overview", href: `/docs/manual/${version}/api`}, + {name: "Core", href: `/docs/manual/${version}/api/core`}, + {name: "Syntax Lookup", href: "/syntax-lookup"}, + ], }, { name: "Additional Libraries", @@ -16,10 +16,6 @@ let makeCategories: string => array = version => [ {name: "Dom", href: `/docs/manual/${version}/api/dom`}, ], }, - { - name: "Legacy Modules", - items: [{name: "Js", href: `/docs/manual/${version}/api/js`}], - }, ] /* Used for API docs (structured data) */