I would like to use K6 Browser to capture response times for specific events. For example I would like to know exactly how long it takes to log on and how long for the search to complete. What is the best way to do this so that the metrics can be sent to grafana.
wait for logon
Wait for Search
I could do the following but this information is not sent to the summary or grafana by default:
const requestDate = new Date();
// your request: await request …
const responseDate = new Date();
console.log(responseDate - requestDate)