MCPcopy Create free account
hub / github.com/krasimir/react-in-patterns / getComponentName

Function getComponentName

code/one-direction-data-flow/public/app.js:3751–3771  ·  view source on GitHub ↗
(fiber)

Source from the content-addressed store, hash-verified

3749}
3750
3751function getComponentName(fiber) {
3752 var type = fiber.type;
3753
3754 if (typeof type === 'function') {
3755 return type.displayName || type.name;
3756 }
3757 if (typeof type === 'string') {
3758 return type;
3759 }
3760 switch (type) {
3761 case REACT_FRAGMENT_TYPE:
3762 return 'ReactFragment';
3763 case REACT_PORTAL_TYPE:
3764 return 'ReactPortal';
3765 case REACT_CALL_TYPE:
3766 return 'ReactCall';
3767 case REACT_RETURN_TYPE:
3768 return 'ReactReturn';
3769 }
3770 return null;
3771}
3772
3773function describeFiber(fiber) {
3774 switch (fiber.tag) {

Callers 15

describeFiberFunction · 0.70
isMountedFunction · 0.70
app.jsFile · 0.70
beginFiberMarkFunction · 0.70
clearFiberMarkFunction · 0.70
endFiberMarkFunction · 0.70
stopWorkLoopTimerFunction · 0.70
checkClassInstanceFunction · 0.70
constructClassInstanceFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected