javascript - Any way to debug tasks and microtasks? - Stack Overflow

Disclaimer: tasks and microtasks are still quite blurry to me.I'm running into some issue and I

Disclaimer: tasks and microtasks are still quite blurry to me.

I'm running into some issue and I think timing is to blame.

I'm maintaining a project that uses a lot of setTimeout(... , 0).

Is it possible to peer into browser's event loop and see what tasks are in the task's and microtask's queue?

I could try to use chrome's devtools timeline or slap some debugger keywords but it is quite tedious.

Disclaimer: tasks and microtasks are still quite blurry to me.

I'm running into some issue and I think timing is to blame.

I'm maintaining a project that uses a lot of setTimeout(... , 0).

Is it possible to peer into browser's event loop and see what tasks are in the task's and microtask's queue?

I could try to use chrome's devtools timeline or slap some debugger keywords but it is quite tedious.

Share Improve this question asked Nov 24, 2015 at 19:45 user1463822user1463822 8879 silver badges25 bronze badges 1
  • 4 Maybe this helps: html5rocks./en/tutorials/developertools/async-call-stack – m90 Commented Nov 24, 2015 at 19:47
Add a ment  | 

1 Answer 1

Reset to default 3

I could try to use chrome's devtools timeline or slap some debugger keywords but it is quite tedious

Well, there are no shortcuts. You need breakpoints, browser developer tools and a lot of patience.

You could also make an attempt at visualizing the javascript runtime code using the loupe tool. This is the source code if you want to play around or extend it: https://github./latentflip/loupe

This project is still at the beginning and there's no way to guarantee it'll reach maturity, so best would be to dig into developer tool documentation and make use of it, as tedious as it might be

发布者:admin,转转请注明出处:http://www.yc00.com/questions/1744398705a4572275.html

相关推荐

  • javascript - Any way to debug tasks and microtasks? - Stack Overflow

    Disclaimer: tasks and microtasks are still quite blurry to me.I'm running into some issue and I

    7天前
    30

发表回复

评论列表(0条)

  • 暂无评论

联系我们

400-800-8888

在线咨询: QQ交谈

邮件:admin@example.com

工作时间:周一至周五,9:30-18:30,节假日休息

关注微信