3 ms·
> log levels matter. Logging messages are structured data. Swift has those [0][1] and other features like jumping to the file and line of code from where the
by Razengan 3y ago
> log levels matter. Logging messages are structured data.
Swift has those [0][1] and other features like jumping to the file and line of code from where the log was generated, but I wish there was a way to easily add extra information to each message in the debug console such as the current frame being rendered etc. Something I've been wrestling to do for the past few days, but if I write a custom logging function, then the IDE's debug console thinks every log message was generated from my custom function.
And god I wish we started making use of COLOR within text-heavy information. Being able to color different words/values in a log message would massively improve readability and comprehension.
[0] https://developer.apple.com/documentation/os/logging https://developer.apple.com/documentation/os/logging
[1] https://developer.apple.com/wwdc23/10226 https://developer.apple.com/wwdc23/10226
- appplication 3y agoI only used it once for a class in grad school, but it’s things like this that make Swift feel like a really well intentioned programming language, especially paired with the xcode ecosystem.