Version: v0.8.1 - Beta.  We welcome contributors & feedback.

Log.trace

trace($stringOrMap) -> self

Description

Appends a TRACE level message to data/logs/app.log as a line of JSON.

Log.trace('Hello Log')

// {"date":"2024-09-18 00:14:37","level":"TRACE","url":"/your/page",message":"Hello Log"}}

You can also pass in a Map of data, which will be serialized and merged with the event data.

Log.trace({ userId: 1234, event: 'loggedIn' })

// {"date":"2024-09-18 00:14:37","level":"TRACE","url":"/your/page","userId":1234,"event":"loggedIn"}}

See Also