Logs can be used to store pretty much anything to your interface. Let’s create our first log.
Logs appear as rows in tables, and fields appear as columns
If you want to incrementally update the same log (row),
then you can use with unify.Log():
to create a logging context,
and all calls to unify.log
will then update this existing log.
These can also be arbitrarily nested. Note that the most recently created log is always shown at the top of the table (not most recently updated).
We can also pass arguments, which will also be part of the same log.
Using with unify.Log()
as often as possible is generally recommended,
as this avoids the need to pass explicit log handles throughout your program.
The code below uses explicit handles (each function has a log
argument):
The code below logs the same data, but avoids the need to pass the Log
instance around:
Both result in the same log:
Logs can be used to store pretty much anything to your interface. Let’s create our first log.
Logs appear as rows in tables, and fields appear as columns
If you want to incrementally update the same log (row),
then you can use with unify.Log():
to create a logging context,
and all calls to unify.log
will then update this existing log.
These can also be arbitrarily nested. Note that the most recently created log is always shown at the top of the table (not most recently updated).
We can also pass arguments, which will also be part of the same log.
Using with unify.Log()
as often as possible is generally recommended,
as this avoids the need to pass explicit log handles throughout your program.
The code below uses explicit handles (each function has a log
argument):
The code below logs the same data, but avoids the need to pass the Log
instance around:
Both result in the same log: