MCPcopy Create free account
hub / github.com/plotly/dash / reenableLogs

Function reenableLogs

dash/deps/react-dom@18.2.0.js:937–979  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

935 }
936 }
937 function reenableLogs() {
938 {
939 disabledDepth--;
940
941 if (disabledDepth === 0) {
942 /* eslint-disable react-internal/no-production-logging */
943 var props = {
944 configurable: true,
945 enumerable: true,
946 writable: true
947 }; // $FlowFixMe Flow thinks console is immutable.
948
949 Object.defineProperties(console, {
950 log: assign({}, props, {
951 value: prevLog
952 }),
953 info: assign({}, props, {
954 value: prevInfo
955 }),
956 warn: assign({}, props, {
957 value: prevWarn
958 }),
959 error: assign({}, props, {
960 value: prevError
961 }),
962 group: assign({}, props, {
963 value: prevGroup
964 }),
965 groupCollapsed: assign({}, props, {
966 value: prevGroupCollapsed
967 }),
968 groupEnd: assign({}, props, {
969 value: prevGroupEnd
970 })
971 });
972 /* eslint-enable react-internal/no-production-logging */
973 }
974
975 if (disabledDepth < 0) {
976 error('disabledDepth fell below zero. ' + 'This is a bug in React. Please file an issue.');
977 }
978 }
979 }
980
981 var ReactCurrentDispatcher = ReactSharedInternals.ReactCurrentDispatcher;
982 var prefix;

Callers 1

Calls 1

errorFunction · 0.70

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…