forked from nodejs/nodejs.org
-
Notifications
You must be signed in to change notification settings - Fork 0
/
next.mdx.use.client.mjs
39 lines (36 loc) · 1.14 KB
/
next.mdx.use.client.mjs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
'use strict';
import Blockquote from './components/Common/Blockquote';
import Button from './components/Common/Button';
import LinkWithArrow from './components/Downloads/Release/LinkWithArrow';
import Link from './components/Link';
import MDXCodeBox from './components/MDX/CodeBox';
import MDXCodeTabs from './components/MDX/CodeTabs';
import MDXImage from './components/MDX/Image';
/**
* A full list of React Components that we want to pass through to MDX
*
* @satisfies {import('mdx/types').MDXComponents}
*/
export const clientMdxComponents = {
// Renders MDX CodeTabs
CodeTabs: MDXCodeTabs,
// Renders a Button Component for `button` tags
Button: Button,
// Links with External Arrow
LinkWithArrow: LinkWithArrow,
};
/**
* A full list of wired HTML elements into custom React Components
*
* @type {import('mdx/types').MDXComponents}
*/
export const htmlComponents = {
// Renders a Link Component for `a` tags
a: Link,
// Renders a Blockquote Component for `blockquote` tags
blockquote: Blockquote,
// Renders a CodeBox Component for `pre` tags
pre: MDXCodeBox,
// Renders an Image Component for `img` tags
img: MDXImage,
};