Skip to content

Commit

Permalink
[docs] Fix 301 links for SEO
Browse files Browse the repository at this point in the history
  • Loading branch information
oliviertassinari committed Sep 9, 2023
1 parent 5be2780 commit eabff88
Show file tree
Hide file tree
Showing 13 changed files with 16 additions and 16 deletions.
4 changes: 2 additions & 2 deletions docs/data/joy/components/link/link.md
Original file line number Diff line number Diff line change
Expand Up @@ -112,9 +112,9 @@ In this situation, the Link will inherit the typographic level scale from its Ty

The sections below explain how to integrate the Link component with third-party tools that have their own comparable component.

### Next.js
### Next.js Pages Router

Here is an example with the [Link component](https://nextjs.org/docs/api-reference/next/link) of Next.js:
Here is an example with the [Link component](https://nextjs.org/docs/pages/api-reference/components/link) of Next.js:

```js
import NextLink from 'next/link';
Expand Down
2 changes: 1 addition & 1 deletion docs/data/joy/customization/dark-mode/dark-mode.md
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@ To [prevent the UI from flickering](/joy-ui/main-features/dark-mode-optimization

### Next.js Pages Router

To use the Joy UI API with a Next.js project, add the following code to the custom [`pages/_document.js`](https://nextjs.org/docs/advanced-features/custom-document) file:
To use the Joy UI API with a Next.js project, add the following code to the custom [`pages/_document.js`](https://nextjs.org/docs/pages/building-your-application/routing/custom-document) file:

```jsx
import Document, { Html, Head, Main, NextScript } from 'next/document';
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -182,9 +182,9 @@ The `mode` is stored inside `CssVarsProvider` which handles local storage synchr
The `getInitColorSchemeScript()` API prevents dark-mode flickering by returning a script that must be run before React.
### Next.js
### Next.js Pages Router
Place the script before `<Main />` in your [`pages/_document.js`](https://nextjs.org/docs/advanced-features/custom-document):
Place the script before `<Main />` in your [`pages/_document.js`](https://nextjs.org/docs/pages/building-your-application/routing/custom-document):
```jsx
import Document, { Html, Head, Main, NextScript } from 'next/document';
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,7 @@ Place `getInitColorSchemeScript()` before the `<Main />` tag to prevent the dark
### Next.js Pages Router
Add the following code to the custom [`pages/_document.js`](https://nextjs.org/docs/advanced-features/custom-document) file:
Add the following code to the custom [`pages/_document.js`](https://nextjs.org/docs/pages/building-your-application/routing/custom-document) file:
```jsx
import Document, { Html, Head, Main, NextScript } from 'next/document';
Expand Down
2 changes: 1 addition & 1 deletion docs/data/material/getting-started/support/support.md
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ and
<a
data-ga-event-category="support"
data-ga-event-action="tidelift"
href="https://tidelift.com/subscription/request-a-demo?utm_source=npm-material-ui&utm_medium=referral&utm_campaign=enterprise">
href="https://tidelift.com/solutions/schedule-demo?utm_source=npm-material-ui&utm_medium=referral&utm_campaign=enterprise">
request a demo today.
</a>

Expand Down
2 changes: 1 addition & 1 deletion docs/data/material/guides/routing/routing.md
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ const LinkBehavior = React.forwardRef((props, ref) => (

### Next.js Pages Router

The [example folder](https://github.com/mui/material-ui/tree/HEAD/examples/material-ui-nextjs-pages-router-ts) provides an adapter for the use of [Next.js's Link component](https://nextjs.org/docs/api-reference/next/link) with Material UI.
The [example folder](https://github.com/mui/material-ui/tree/HEAD/examples/material-ui-nextjs-pages-router-ts) provides an adapter for the use of [Next.js's Link component](https://nextjs.org/docs/pages/api-reference/components/link) with Material UI.

- The first version of the adapter is the [`NextLinkComposed`](https://github.com/mui/material-ui/blob/-/examples/material-ui-nextjs-pages-router-ts/src/Link.tsx) component.
This component is unstyled and only responsible for handling the navigation.
Expand Down
4 changes: 2 additions & 2 deletions docs/src/modules/components/Link.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -66,8 +66,8 @@ export type LinkProps = {
} & Omit<NextLinkComposedProps, 'to' | 'linkAs' | 'href'> &
Omit<MuiLinkProps, 'href'>;

// A styled version of the Next.js Link component:
// https://nextjs.org/docs/api-reference/next/link
// A styled version of the Next.js Pages Router Link component:
// https://nextjs.org/docs/pages/api-reference/components/link
const Link = React.forwardRef<HTMLAnchorElement, LinkProps>(function Link(props, ref) {
const {
activeClassName = 'active',
Expand Down
2 changes: 1 addition & 1 deletion examples/material-ui-nextjs-pages-router-ts/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ It includes `@mui/material` and its peer dependencies, including [Emotion](https

## The link component

The [example folder](https://github.com/mui/material-ui/tree/HEAD/examples/material-ui-nextjs-pages-router-ts) provides an adapter for the use of [Next.js's Link component](https://nextjs.org/docs/api-reference/next/link) with MUI.
The [example folder](https://github.com/mui/material-ui/tree/HEAD/examples/material-ui-nextjs-pages-router-ts) provides an adapter for the use of [Next.js's Link component](https://nextjs.org/docs/pages/api-reference/components/link) with MUI.
More information [in the documentation](https://mui.com/material-ui/guides/routing/#next-js).

## What's next?
Expand Down
2 changes: 1 addition & 1 deletion examples/material-ui-nextjs-pages-router-ts/src/Link.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ export type LinkProps = {
Omit<MuiLinkProps, 'href'>;

// A styled version of the Next.js Link component:
// https://nextjs.org/docs/api-reference/next/link
// https://nextjs.org/docs/pages/api-reference/components/link
const Link = React.forwardRef<HTMLAnchorElement, LinkProps>(function Link(props, ref) {
const {
activeClassName = 'active',
Expand Down
2 changes: 1 addition & 1 deletion examples/material-ui-nextjs-pages-router/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ If you prefer, you can [use styled-components instead](https://mui.com/material-

## The Link component

The [example folder](https://github.com/mui/material-ui/tree/HEAD/examples/material-ui-nextjs-pages-router) provides an adapter for the use of [Next.js's Link component](https://nextjs.org/docs/api-reference/next/link) with MUI.
The [example folder](https://github.com/mui/material-ui/tree/HEAD/examples/material-ui-nextjs-pages-router) provides an adapter for the use of [Next.js's Link component](https://nextjs.org/docs/pages/api-reference/components/link) with MUI.
More information [in the documentation](https://mui.com/material-ui/guides/routing/#next-js).

## What's next?
Expand Down
2 changes: 1 addition & 1 deletion examples/material-ui-nextjs-pages-router/src/Link.js
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ NextLinkComposed.propTypes = {
};

// A styled version of the Next.js Link component:
// https://nextjs.org/docs/api-reference/next/link
// https://nextjs.org/docs/pages/api-reference/components/link
const Link = React.forwardRef(function Link(props, ref) {
const {
activeClassName = 'active',
Expand Down
2 changes: 1 addition & 1 deletion examples/material-ui-nextjs-ts-v4-v5-migration/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,6 @@ It demonstrates what results after handling v5's breaking changes to the [theme]

## The Link component

Next.js has [a custom Link component](https://nextjs.org/docs/api-reference/next/link).
Next.js has [a custom Link component](https://nextjs.org/docs/pages/api-reference/components/link).
The example folder provides adapters for usage with Material UI.
You can find more information [in the documentation](https://mui.com/material-ui/guides/routing/#next-js).
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ export type LinkProps = {
Omit<MuiLinkProps, 'href'>;

// A styled version of the Next.js Link component:
// https://nextjs.org/docs/api-reference/next/link
// https://nextjs.org/docs/pages/api-reference/components/link
const Link = React.forwardRef<HTMLAnchorElement, LinkProps>(function Link(props, ref) {
const {
activeClassName = 'active',
Expand Down

0 comments on commit eabff88

Please sign in to comment.