-
Notifications
You must be signed in to change notification settings - Fork 43
Open
Description
The following code:
type NestedArray<T> = (T | NestedArray<T>)[];
export type Props = {
numbers: NestedArray<number>,
};
produces the following error:
RangeError: Maximum call stack size exceeded
at Array.map (<anonymous>)
20 | }
21 | else if (node.type === 'UnionTypeAnnotation') {
> 22 | const realTypes = node.types.map(n => mapGenericToRealType(n, typeParamMapping));
| ^
23 | const newNode = Object.assign({}, node, {
24 | types: realTypes,
25 | });
at map (src/convertToPropTypes.js:22:34)
...
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels