Drawing tool for javascript?

Hello

is there a tool something like this http://www.brainblitz.org/BoxCAD/ but for javascript version? I googled a lot and did not find. I found for flash, for java. But this for flashh is very lagggin. For java it was ok, and it generates objetcs in JSON format, so also I would accept library which reads that info from java generated json and make javascript code.

Otherwise its hard to draw, when you just put coordinates and cannot see ritght away what figure you are getting. Its a wasted of time..
for example I want to draw a tube where the ball can fall in and ride accordign to physics: I have made it with paint using paint. But how can I quickly make in the code? I have to find coordinates somehow for each posible point. WHich is not efective 🙁

Image
Not entirely sure if its what you're asking for but RUBE:https://www.iforce2d.net/rube/ can export worlds to json which can be loaded into box2dweb.

Original thread: https://box2d.org/forum/viewtopic.php?t=8938