Skip to content

Commit ecb302e

Browse files
hakonkroghPlopix
authored andcommitted
fix(reactjs-components): corrected NodeProps type - not a tuple
1 parent 078720b commit ecb302e

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/content-transformer/component.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ export const Renderers = {
8585

8686
export interface Props {
8787
overrides?: Overrides | null;
88-
json?: [NodeProps] | NodeProps;
88+
json?: NodeProps[] | NodeProps;
8989
}
9090

9191
export const OverridesContext = createContext<Overrides | null>(null);
@@ -166,7 +166,7 @@ export const ContentTransformer = ({ overrides = null, json }: Props) => {
166166
}
167167

168168
if (Array.isArray(json)) {
169-
const nodes: [NodeProps] = json;
169+
const nodes: NodeProps[] = json;
170170
return (
171171
<OverridesContext.Provider value={overrides}>
172172
{nodes.map((j, i) => (

0 commit comments

Comments
 (0)