Zero dependency Swift stopwatch. Figurable in seconds !
Overall Stopwatch
usage is fairly straightforward.
You mark beginning of the measurement interval and probe elapsed time at desired moment.
Simple use case coud be:
function doSomething() {
// Mark beginning of measuring interval
Stopwatch.begin()
somethingThatTakesTime()
// Show elapsed time string
print("Elapsed: \(Stopwatch.elapsed)")
}
Stopwatch can be easily installed using SPM
.
Package name: Stopwatch
Package URL: https://github.com/vexy/Stopwatch
And that's it. Enjoy!
Copyright (c) Vex 2023
PGP: 6302 D860 B74C BD34 6482 DBA2 5187 66D0 8213 DBC0