Commit 0348556a authored by gabime's avatar gabime

Added stopwatch example to README.md

parent d6329b9d
......@@ -169,6 +169,21 @@ spdlog::flush_every(std::chrono::seconds(3));
```
---
#### Stopwatch
```c++
// Stopwatch support for spdlog (using std::chrono::high_resolution_clock).
// Displays elapsed seconds since construction as double.
#include "spdlog/stopwatch.h"
void stopwatch_example()
{
spdlog::stopwatch sw;
spdlog::debug("Elapsed {}", sw);
spdlog::debug("Elapsed {:.3}", sw);
}
```
---
#### Log binary data in hex
```c++
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment