An implementation of a virtual dom lib for educational purposes.
virtual-dom allows you to update a view whenever state changes by creating a full VTree of the view and then patching the DOM efficiently to look exactly as you described it. This results in keeping manual DOM manipulation and previous state tracking out of your application code, promoting clean and maintainable rendering logic for web applications.
My version supports adding, removing, updating with diffing DOM elements dynamically. It also "supports" custom props / events.
Next step: use it for a React-like rendering library!
yarn install && yarn babel && yarn start
npm, yarn
Thanks to @deathmood for his fantastic tutorial.