(view: FunctionComponent)
| 61 | } |
| 62 | |
| 63 | export function wrapReactClass(view: FunctionComponent) { |
| 64 | let ViewComponentClass = class extends Component { |
| 65 | render() { |
| 66 | const { children, ...other } = this.props; |
| 67 | return createElement(view, other, children); |
| 68 | } |
| 69 | } as any; |
| 70 | ViewComponentClass = cloneEnumerableProperty(ViewComponentClass, view); |
| 71 | ViewComponentClass.displayName = view.displayName; |
| 72 | return ViewComponentClass; |
| 73 | } |
no test coverage detected
searching dependent graphs…