Home > Software engineering >  How to write from ReactNative to Apple's unified log in the Simulator
How to write from ReactNative to Apple's unified log in the Simulator

Time:01-09

I'd like to log some values in ReactNative but not to the console or to a file, I'd like to log data to Apple's unified log while I'm running in the iPhone Simulator.

In other words, I'd like to achieve the same as this line in Swift that writes to the log and the data can be inspected in Console.app:

os_log("This is a debug log line")

Is there a way to do that with JavaScript in ReactNative?

CodePudding user response:

Try this package react-native-os-logger

  • Related