DEV Community

Discussion on: Abstract Syntax Trees: They're Actually Used Everywhere -- But What Are They?

Collapse
 
aruna profile image
aruna-x

Hey Josh, that’s great to hear! I’m happy to write a follow up on injecting code. Coming soon 😄 I’m curious what project you’re working on.

Collapse
 
pulljosh profile image
Josh Pullen • Edited

I am working on a JavaScript editor that enables you to debug your code by time traveling:

I hope it will help new developers understand the language better. (I've been heavily inspired by the work of Bret Victor.)

The main trick here is to inject function calls into the user's code which report back information about the state of the program. That's how the timeline of values is built.

Thread Thread
 
aruna profile image
aruna-x

Josh! Apologies for the delay. I actually had a family emergency. This project sounds amazing! I won’t have a chance to write that blog post quickly enough, but I’d be happy to hop on a quick call to chat about what I learned and how you can apply it to your project. Let me know :)

Thread Thread
 
pulljosh profile image
Josh Pullen

Sorry to hear about your family. :( Hope things are getting better for you.

I would love to chat if you have the time! You are very kind to offer; I'm sure there's a lot I could learn from you.

I've been making progress on my babel plugin to inject the diagnostic function calls, but I am definitely just hacking around as I build it. There are probably lots of things I could be doing in a better way.

If you're still interested in talking, you can shoot me an email or a DM on twitter. :)