Skip to content

Latest commit

History

History
25 lines (14 loc) 路 757 Bytes

File metadata and controls

25 lines (14 loc) 路 757 Bytes

Measuring execution time in Dart

Ever wanted to measure how long a network request takes in Dart?

This is easily done by creating a helper function that calculates the difference between two dates. 馃憞


Then, you can wrap any asynchronous code block inside the function and reuse it as needed.

Very useful for benchmarking the execution time of your backend or database calls. 馃憣


Found this useful? Show some love and share the original tweet 馃檹


Previous Next
Find the Invalid Switch Expression 馃 Are global variables bad?