Skip to content

Commit

Permalink
upd README
Browse files Browse the repository at this point in the history
  • Loading branch information
ghostiam authored and david-littlefarmer committed Jun 26, 2024
1 parent c890902 commit d10c886
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ opts := &devslog.Options{
TimeFormat: "[04:05]",
NewLineAfterLog: true,
DebugColor: devslog.Magenta,
StringerFormatter: true,
}

logger := slog.New(devslog.NewHandler(os.Stdout, opts))
Expand All @@ -61,6 +62,7 @@ opts := &devslog.Options{
MaxSlicePrintSize: 4,
SortKeys: true,
NewLineAfterLog: true,
StringerFormatter: true,
}

logger := slog.New(devslog.NewHandler(os.Stdout, opts))
Expand All @@ -85,6 +87,7 @@ if production {
MaxSlicePrintSize: 10,
SortKeys: true,
NewLineAfterLog: true,
StringerFormatter: true,
}

logger = slog.New(devslog.NewHandler(os.Stdout, opts))
Expand All @@ -107,3 +110,4 @@ slog.SetDefault(logger)
| WarnColor | Color for Warn level | devslog.Yellow | devslog.Color (uint) |
| ErrorColor | Color for Error level | devslog.Red | devslog.Color (uint) |
| MaxErrorStackTrace | Max stack trace frames for errors | 0 | uint |
| StringerFormatter | Use Stringer interface for formatting | false | bool |

0 comments on commit d10c886

Please sign in to comment.