Embed a Video
Videos can be embedded in a page using the MDX markdown file types.
#
YoutubeGet the id of the youtube video you want to embed.
#
Example videoIn the link address of https://www.youtube.com/watch?v=fNxaJsNG3-s
, the id of the video is fNxaJsNG3-s
#
Import react-youtubeSay your file name is my-embed-video-page.mdx
, and it is located inside docs
folder:
my-embed-video-page.mdx
All you need to do is replace the videoId
parameter value with the id of your youtube video.
The video embed will be rendered after the h1 tag Tokenization
.