Skip to content

Commit

Permalink
quick fix
Browse files Browse the repository at this point in the history
  • Loading branch information
Josh-Cena committed Jun 11, 2022
1 parent 43d0af3 commit a1bf90c
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion packages/docusaurus/src/commands/swizzle/actions.ts
Expand Up @@ -125,7 +125,10 @@ export async function wrap({
import ${componentName} from '@theme-${importType}/${themeComponentName}';
import type ${componentName}Type from '@theme/${themeComponentName}';
type Props = ComponentProps<typeof ${componentName}Type>;
type RawProps = ComponentProps<typeof ${componentName}Type>;
// ComponentProps is a little buggy, quick fix.
// https://github.com/DefinitelyTyped/DefinitelyTyped/discussions/60766
type Props = unknown extends RawProps ? object : RawProps;
export default function ${wrapperComponentName}(props: Props): JSX.Element {
return (
Expand Down

0 comments on commit a1bf90c

Please sign in to comment.