Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/joao208/didactic-parakeet
Log Time is a console-based time logger for node.js that can help you track execution time of your functions and libraries.
https://github.com/joao208/didactic-parakeet
javascript npm time typescript
Last synced: 14 days ago
JSON representation
Log Time is a console-based time logger for node.js that can help you track execution time of your functions and libraries.
- Host: GitHub
- URL: https://github.com/joao208/didactic-parakeet
- Owner: Joao208
- Created: 2022-08-23T23:01:59.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2022-08-26T14:48:39.000Z (over 2 years ago)
- Last Synced: 2024-12-07T14:33:42.491Z (18 days ago)
- Topics: javascript, npm, time, typescript
- Language: TypeScript
- Homepage:
- Size: 91.8 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Time to get productive
Log Time is a console-based time logger for node.js that can help you track execution time of your functions and libraries. And everthing with only two methods.
[![MIT License](https://img.shields.io/badge/License-MIT-green.svg)](https://choosealicense.com/licenses/mit/)
[![codecov](https://codecov.io/gh/Joao208/didactic-parakeet/branch/main/graph/badge.svg?token=CCI03J2T00)](https://codecov.io/gh/Joao208/didactic-parakeet)## Install
You can install with npm or yarn
```bash
yarn add console-time
``````bash
npm install console-time
```## Example of uses
```javascript
import LogTime from 'console-time'const myTime = new LogTime(console.log) // here you pass your logging method
myTime.start()
func() {
// make you code here
}myTime.stop('My function delayed {{seconds}} seconds') // My function delayed 2 seconds
```## Times documentation
| Variable | Whats mean |
| ------------ | --------------------------------- |
| milliseconds | Time of execution in milliseconds |
| seconds | Time of execution is seconds |
| minutes | Time of execution in minutes |
| hours | Time of execution in hours |
| days | Time of execution in days |