Skip to content

Commit 3e0510c

Browse files
authored
Use Serilog.Formatting.Compact in JSON example [Skip CI]
1 parent d636b08 commit 3e0510c

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

README.md

+3-2
Original file line numberDiff line numberDiff line change
@@ -160,10 +160,11 @@ The default format above corresponds to an output template like:
160160

161161
##### JSON event formatting
162162

163-
To write events to the file in an alternative format such as JSON, pass an `ITextFormatter` as the first argument:
163+
To write events to the file in an alternative format such as [JSON](https://github.com/serilog/serilog-formatting-compact), pass an `ITextFormatter` as the first argument:
164164

165165
```csharp
166-
.WriteTo.File(new JsonFormatter(), "log.txt")
166+
// Install-Package Serilog.Formatting.Compact
167+
.WriteTo.File(new CompactJsonFormatter(), "log.txt")
167168
```
168169

169170
### Shared log files

0 commit comments

Comments
 (0)