All Projects → bevacqua → Diferente

bevacqua / Diferente

Licence: mit
User-friendly virtual DOM diffing

Programming Languages

javascript
184084 projects - #8 most used programming language

diferente

User-friendly virtual DOM diffing

Demo

Demo screenshot

Install

npm install diferente --save
bower install diferente --save

diferente(el, markup)

In contrast with el.innerHTML = markup, which wipes out the DOM when set, diferente allows you to easily swap out markup with an intelligent virtual-dom changeset diff patch.

diferente(el, '<new markup to diff/>');

Origins

The diffhtml algorithm was invented by tbranyen. I wanted something that didn't pollute the environment (his code assigned to Element.prototype.diffHTML), so I took the code he wrote and just exposed the function that was called when assigning to diffHTML. All credit goes to him.

License

MIT

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].