docs: change configurations to make v2 the main docs (#9729)
* docs: change configurations to make v2 the main docs * move api routes to top level * remove api prefix * update opengraph images * show v1 link * add redirect to v1
This commit is contained in:
@@ -38,12 +38,12 @@ export const MainNavDesktopMenu = () => {
|
||||
title: "Homepage",
|
||||
link: "https://medusajs.com",
|
||||
},
|
||||
// {
|
||||
// type: "link",
|
||||
// icon: <BookIcon />,
|
||||
// title: "Medusa v1",
|
||||
// link: "https://docs.medusajs.com",
|
||||
// },
|
||||
{
|
||||
type: "link",
|
||||
icon: <BookIcon />,
|
||||
title: "Medusa v1",
|
||||
link: "https://docs.medusajs.com/v1",
|
||||
},
|
||||
{
|
||||
type: "link",
|
||||
icon: <TimelineVertical />,
|
||||
@@ -54,7 +54,7 @@ export const MainNavDesktopMenu = () => {
|
||||
type: "link",
|
||||
icon: <QuestionMarkCircle />,
|
||||
title: "Troubleshooting",
|
||||
link: "https://docs.medusajs.com/v2/resources/troubleshooting",
|
||||
link: "https://docs.medusajs.com/resources/troubleshooting",
|
||||
},
|
||||
]
|
||||
|
||||
|
||||
@@ -50,7 +50,7 @@ export const MainNav = ({ className, itemsClassName }: MainNavProps) => {
|
||||
<SidebarLeftIcon />
|
||||
</Button>
|
||||
)}
|
||||
<Link href={`${config.baseUrl}/v2`}>
|
||||
<Link href={`${config.baseUrl}`}>
|
||||
<BorderedIcon
|
||||
IconComponent={MedusaIcon}
|
||||
iconWrapperClassName="my-[14px]"
|
||||
|
||||
@@ -7,7 +7,7 @@ export const GITHUB_UI_ISSUES_PREFIX = `https://github.com/medusajs/ui/issues/ne
|
||||
export const navDropdownItems: NavigationItem[] = [
|
||||
{
|
||||
type: "link",
|
||||
path: `/v2/learn`,
|
||||
path: `/learn`,
|
||||
title: "Get Started",
|
||||
project: "book",
|
||||
},
|
||||
@@ -18,12 +18,12 @@ export const navDropdownItems: NavigationItem[] = [
|
||||
{
|
||||
type: "link",
|
||||
title: "Commerce Modules",
|
||||
link: "/v2/resources/commerce-modules",
|
||||
link: "/resources/commerce-modules",
|
||||
},
|
||||
{
|
||||
type: "link",
|
||||
title: "Architectural Modules",
|
||||
link: "/v2/resources/architectural-modules",
|
||||
link: "/resources/architectural-modules",
|
||||
},
|
||||
],
|
||||
},
|
||||
@@ -34,18 +34,18 @@ export const navDropdownItems: NavigationItem[] = [
|
||||
{
|
||||
type: "link",
|
||||
title: "Guides",
|
||||
link: "/v2/resources",
|
||||
link: "/resources",
|
||||
useAsFallback: true,
|
||||
},
|
||||
{
|
||||
type: "link",
|
||||
title: "Examples",
|
||||
link: "/v2/resources/examples",
|
||||
link: "/resources/examples",
|
||||
},
|
||||
{
|
||||
type: "link",
|
||||
title: "Recipes",
|
||||
link: "/v2/resources/recipes",
|
||||
link: "/resources/recipes",
|
||||
},
|
||||
{
|
||||
type: "divider",
|
||||
@@ -53,12 +53,12 @@ export const navDropdownItems: NavigationItem[] = [
|
||||
{
|
||||
type: "link",
|
||||
title: "Admin Components",
|
||||
link: "/v2/resources/admin-components",
|
||||
link: "/resources/admin-components",
|
||||
},
|
||||
{
|
||||
type: "link",
|
||||
title: "Storefront Development",
|
||||
link: "/v2/resources/storefront-development",
|
||||
link: "/resources/storefront-development",
|
||||
},
|
||||
{
|
||||
type: "link",
|
||||
@@ -74,17 +74,17 @@ export const navDropdownItems: NavigationItem[] = [
|
||||
{
|
||||
type: "link",
|
||||
title: "Medusa CLI",
|
||||
link: "/v2/resources/medusa-cli",
|
||||
link: "/resources/medusa-cli",
|
||||
},
|
||||
{
|
||||
type: "link",
|
||||
title: "JS SDK",
|
||||
link: "/v2/resources/js-sdk",
|
||||
link: "/resources/js-sdk",
|
||||
},
|
||||
{
|
||||
type: "link",
|
||||
title: "Next.js Starter",
|
||||
link: "/v2/resources/nextjs-starter",
|
||||
link: "/resources/nextjs-starter",
|
||||
},
|
||||
{
|
||||
type: "divider",
|
||||
@@ -92,7 +92,7 @@ export const navDropdownItems: NavigationItem[] = [
|
||||
{
|
||||
type: "link",
|
||||
title: "Integrations",
|
||||
link: "/v2/resources/integrations",
|
||||
link: "/resources/integrations",
|
||||
},
|
||||
],
|
||||
},
|
||||
@@ -103,32 +103,32 @@ export const navDropdownItems: NavigationItem[] = [
|
||||
{
|
||||
type: "link",
|
||||
title: "API Routes",
|
||||
link: "/v2/learn/basics/api-routes",
|
||||
link: "/learn/basics/api-routes",
|
||||
},
|
||||
{
|
||||
type: "link",
|
||||
title: "Modules",
|
||||
link: "/v2/learn/basics/modules",
|
||||
link: "/learn/basics/modules",
|
||||
},
|
||||
{
|
||||
type: "link",
|
||||
title: "Subscribers",
|
||||
link: "/v2/learn/basics/events-and-subscribers",
|
||||
link: "/learn/basics/events-and-subscribers",
|
||||
},
|
||||
{
|
||||
type: "link",
|
||||
title: "Scheduled Jobs",
|
||||
link: "/v2/learn/basics/scheduled-jobs",
|
||||
link: "/learn/basics/scheduled-jobs",
|
||||
},
|
||||
{
|
||||
type: "link",
|
||||
title: "Loaders",
|
||||
link: "/v2/learn/basics/loaders",
|
||||
link: "/learn/basics/loaders",
|
||||
},
|
||||
{
|
||||
type: "link",
|
||||
title: "Admin Customizations",
|
||||
link: "/v2/learn/basics/admin-customizations",
|
||||
link: "/learn/basics/admin-customizations",
|
||||
},
|
||||
{
|
||||
type: "divider",
|
||||
@@ -136,22 +136,22 @@ export const navDropdownItems: NavigationItem[] = [
|
||||
{
|
||||
type: "link",
|
||||
title: "Links",
|
||||
link: "/v2/learn/advanced-development/module-links",
|
||||
link: "/learn/advanced-development/module-links",
|
||||
},
|
||||
{
|
||||
type: "link",
|
||||
title: "Query",
|
||||
link: "/v2/learn/advanced-development/module-links/query",
|
||||
link: "/learn/advanced-development/module-links/query",
|
||||
},
|
||||
{
|
||||
type: "link",
|
||||
title: "Data Models",
|
||||
link: "/v2/learn/advanced-development/data-models",
|
||||
link: "/learn/advanced-development/data-models",
|
||||
},
|
||||
{
|
||||
type: "link",
|
||||
title: "Workflows",
|
||||
link: "/v2/learn/basics/workflows",
|
||||
link: "/learn/basics/workflows",
|
||||
},
|
||||
],
|
||||
},
|
||||
@@ -162,12 +162,12 @@ export const navDropdownItems: NavigationItem[] = [
|
||||
{
|
||||
type: "link",
|
||||
title: "Admin API",
|
||||
link: "/v2/api/admin",
|
||||
link: "/api/admin",
|
||||
},
|
||||
{
|
||||
type: "link",
|
||||
title: "Store API",
|
||||
link: "/v2/api/store",
|
||||
link: "/api/store",
|
||||
},
|
||||
{
|
||||
type: "divider",
|
||||
@@ -175,27 +175,27 @@ export const navDropdownItems: NavigationItem[] = [
|
||||
{
|
||||
type: "link",
|
||||
title: "Workflows",
|
||||
link: "/v2/resources/medusa-workflows-reference",
|
||||
link: "/resources/medusa-workflows-reference",
|
||||
},
|
||||
{
|
||||
type: "link",
|
||||
title: "Data Model API",
|
||||
link: "/v2/resources/references/data-model",
|
||||
link: "/resources/references/data-model",
|
||||
},
|
||||
{
|
||||
type: "link",
|
||||
title: "Service Factory",
|
||||
link: "/v2/resources/service-factory-reference",
|
||||
link: "/resources/service-factory-reference",
|
||||
},
|
||||
{
|
||||
type: "link",
|
||||
title: "Events Reference",
|
||||
link: "/v2/resources/events-reference",
|
||||
link: "/resources/events-reference",
|
||||
},
|
||||
{
|
||||
type: "link",
|
||||
title: "Admin Widget Injection Zones",
|
||||
link: "/v2/resources/admin-widget-injection-zones",
|
||||
link: "/resources/admin-widget-injection-zones",
|
||||
},
|
||||
],
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user