-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
10 changed files
with
2,164 additions
and
53 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,12 @@ | ||
const withMDX = require('@next/mdx')(); | ||
|
||
/** @type {import('next').NextConfig} */ | ||
const config = { | ||
output: 'export', | ||
reactStrictMode: true, | ||
images: { | ||
unoptimized: true, | ||
}, | ||
}; | ||
|
||
module.exports = config; | ||
module.exports = withMDX(config); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
export const EXAMPLE_PATH = "blog-starter"; | ||
export const CMS_NAME = "Markdown"; | ||
export const DEFAULT_TITLE = "GrapesJS"; | ||
export const HOME_OG_IMAGE_URL = | ||
"https://og-image.vercel.app/Next.js%20Blog%20Starter%20Example.png?theme=light&md=1&fontSize=100px&images=https%3A%2F%2Fassets.vercel.com%2Fimage%2Fupload%2Ffront%2Fassets%2Fdesign%2Fnextjs-black-logo.svg"; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
import Alert from "@/app/_components/alert"; | ||
import { Intro } from "@/app/_components/intro"; | ||
import markdownStyles from "@/app/_components/markdown-styles.module.css"; | ||
import type { MDXComponents } from 'mdx/types'; | ||
import { MDXRemote, MDXRemoteProps } from 'next-mdx-remote/rsc'; | ||
|
||
export function useMDXComponents(components: MDXComponents): MDXComponents { | ||
return { | ||
...components, | ||
} | ||
} | ||
|
||
const mdxComponents = { | ||
Alert, | ||
Intro, | ||
}; | ||
|
||
export function ContainerMDX({ source }: MDXRemoteProps) { | ||
// @ts-ignore | ||
const result = <MDXRemote | ||
components={mdxComponents} | ||
source={source} | ||
/>; | ||
|
||
return ( | ||
<div className={markdownStyles["markdown"]}> | ||
{result} | ||
</div> | ||
); | ||
} |
Oops, something went wrong.