refactor: unify how MDX content types are represented (#7145)

* refactor: unify how MDX content types are represented

* fix

* fix again
This commit is contained in:
Joshua Chen 2022-04-10 19:19:44 +08:00 committed by GitHub
parent b50def3ac0
commit 7a61eed3dd
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 25 additions and 33 deletions

View file

@ -48,19 +48,14 @@ declare module '@docusaurus/plugin-content-pages' {
}
declare module '@theme/MDXPage' {
import type {TOCItem} from '@docusaurus/types';
import type {LoadedMDXContent} from '@docusaurus/mdx-loader';
import type {
MDXPageMetadata,
FrontMatter,
} from '@docusaurus/plugin-content-pages';
export interface Props {
readonly content: {
readonly frontMatter: FrontMatter;
readonly metadata: MDXPageMetadata;
readonly toc: readonly TOCItem[];
(): JSX.Element;
};
readonly content: LoadedMDXContent<FrontMatter, MDXPageMetadata>;
}
export default function MDXPage(props: Props): JSX.Element;