The first number is the count of modules that contain a package that imports this one.
The module count is a better indicator of popularity than the package count.
A module with 100 importing packages is counted only once instead of 100 times,
reflecting the fact that the choice to use the package was likely made only once,
not 100 times.
A '?' means that the value hasn't been computed yet.
The first parameter is the name of the logger. If an empty name is provided, the logger will use the file name and the function name as session id.
The second parameter is the verbose level of the logger. The logger will only log messages with the level equal to or lower than the verbose level. The verbose level is an integer, and the logger provides the following levels:
Static : No message will be logged
Error : Only error messages will be logged
Warn : Error and warning messages will be logged
Develop: All messages will be logged
Use the logger to log messages
Single message
logger.Info("This is an info message")
logger.Warn("This is a warning message")
logger.Success("This is a success message")
logger.Error("This is an error message")
Messages with a title (if the first parameter is type of string)
logger.Info("Title 1", "This is an info message")
logger.Info("Title 2", structA, structB, structC)
// Output:
// - Title 1: This is an info message
// - Title 2: [
// structA {
// ...
// },
// structB {
// ...
// },
// ...
// ]
const (
Static = iota// Sessions set to this level will never print Error // Sessions set to this level will only print errors Warn // Sessions set to this level will print errors and warnings Develop // Developing sessions will print all logs)
Verbose Level for the logger to determine whether to print the log or not