Logs cluttered with unformatted component trees
I have set up a pretty standard react-native-logs configuration for my React Native app. I am using mapConsoleTransport, so that the corresponding console method for the log levels is called and the log level is color-coded in the Metro console.
import { logger, mapConsoleTransport } from "react-native-logs";
const loggerConfig = {
transport: mapConsoleTransport,
levels: {
trace: 0,
debug: 1,
info: 2,
warn: 3,
error: 4,
},
printLevel: true,
severity: "trace",
};
var log = logger.createLogger<"trace" | "debug" | "info" | "warn" | "error">(
loggerConfig,
);
export { log };
Unfortunately, my console is cluttered with junk, so that the significant logs are hard to find:
SceneView@http://192.168.X.XXX:8081/index.bundle//&platform=ios&dev=true&minify=false&modulesOnly=false&runModule=true&app=org.myapp:203353:22
RCTView
View
RCTView
View
RCTView
View
This doesn't happen if I remove the mapConsoleTransport, nor when I just use console.log.
It seems that these are component trees of the components in which the logs were added and they lack proper formatting. How can I remove them?
I could not find a lot information on this issue, so this seems to be a rare case; which is strange regarding that my config is pretty standard.
Can you write a basic example?
reopen if necessary