mirror of
https://github.com/zebrajr/react.git
synced 2026-01-15 12:15:22 +00:00
Add React.Timeout to getComponentName (#12890)
This commit is contained in:
committed by
Dan Abramov
parent
3df157480a
commit
fe747a51c1
@@ -18,6 +18,7 @@ import {
|
||||
REACT_PROFILER_TYPE,
|
||||
REACT_PROVIDER_TYPE,
|
||||
REACT_STRICT_MODE_TYPE,
|
||||
REACT_TIMEOUT_TYPE,
|
||||
} from 'shared/ReactSymbols';
|
||||
|
||||
function getComponentName(fiber: Fiber): string | null {
|
||||
@@ -43,6 +44,8 @@ function getComponentName(fiber: Fiber): string | null {
|
||||
return 'Context.Provider';
|
||||
case REACT_STRICT_MODE_TYPE:
|
||||
return 'StrictMode';
|
||||
case REACT_TIMEOUT_TYPE:
|
||||
return 'Timeout';
|
||||
}
|
||||
if (typeof type === 'object' && type !== null) {
|
||||
switch (type.$$typeof) {
|
||||
|
||||
Reference in New Issue
Block a user