MCPcopy Create free account
hub / github.com/commissure/redbox-react / createComponent

Function createComponent

tests/utils.js:4–8  ·  view source on GitHub ↗
(component, props, ...children)

Source from the content-addressed store, hash-verified

2const TestUtils = require('react-addons-test-utils');
3
4export const createComponent = (component, props, ...children) => {
5 const shallowRenderer = TestUtils.createRenderer()
6 shallowRenderer.render(React.createElement(component, props, children.length > 1 ? children : children[0]))
7 return shallowRenderer.getRenderOutput()
8}

Callers 1

index.jsFile · 0.90

Calls 1

renderMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…