I'm debugging the load times of a page and started using the Timeline feature of Chrome Dev Tools.
What I would like to do is modify my javascript library so that I could write some "events" to the timeline so I could know at what time, the code hit a certain line. But I can see that the timeline only records "real" events: http requests, script evaluations, paint events..
Is there a way to do this?
Yes, you can.
Use console.timeStamp('whatever');
https://developers.google.com/chrome-developer-tools/docs/console-api#consoletimestamplabel
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.