| 14 | |
| 15 | export function wire(Component, deps, mapper) { |
| 16 | return class Injector extends React.Component { |
| 17 | constructor(props) { |
| 18 | super(props); |
| 19 | this._resolvedDependencies = mapper(...deps.map(fetch)); |
| 20 | } |
| 21 | render() { |
| 22 | return ( |
| 23 | <Component |
| 24 | {...this.state} |
| 25 | {...this.props} |
| 26 | {...this._resolvedDependencies} |
| 27 | /> |
| 28 | ); |
| 29 | } |
| 30 | }; |
| 31 | } |
nothing calls this directly
no outgoing calls
no test coverage detected