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

Function getComponentName

code/dependency-injection/public/app.js:3971–3991  ·  view source on GitHub ↗
(fiber)

Source from the content-addressed store, hash-verified

3969}
3970
3971function getComponentName(fiber) {
3972 var type = fiber.type;
3973
3974 if (typeof type === 'function') {
3975 return type.displayName || type.name;
3976 }
3977 if (typeof type === 'string') {
3978 return type;
3979 }
3980 switch (type) {
3981 case REACT_FRAGMENT_TYPE:
3982 return 'ReactFragment';
3983 case REACT_PORTAL_TYPE:
3984 return 'ReactPortal';
3985 case REACT_CALL_TYPE:
3986 return 'ReactCall';
3987 case REACT_RETURN_TYPE:
3988 return 'ReactReturn';
3989 }
3990 return null;
3991}
3992
3993function describeFiber(fiber) {
3994 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