colorful rat Ratfactor.com > Dave's Repos

retrov

A tiny browser-native Virtual DOM rendering library.
git clone http://ratfactor.com/repos/retrov/retrov.git

Commit history

commit 3fed42ea2a2635bca8aa20eda5d392b5ae6e50d7
Author: Dave Gauer 
Date:   Sun Aug 17 22:44:11 2025 -0400

    Now re-rendering raw HTML input if it has changed

commit 95c0ae23d02f7e4dd648a8b67671524325b2c4df
Author: Dave Gauer 
Date:   Sun Mar 23 19:15:31 2025 -0400

    Fixed nested array rendering, added visual debugging to test page
    
    The nested array rendering fix is actually a pretty big change to the
    way RetroV works.
    
    Before, nested arrays (where the array was just a list, not a virtual
    node item) were treated as positional entries in the outer list. If the
    array was empty, a placeholder comment took its place.
    
    After this commit, all non-node arrays are "flattened" so that their
    members are treated as if they were members of the outer array in the
    order encountered.
    
    Empty arrays are flattened out of existence altogether.
    
    As part of this change, the main render function, user_render()
    internally, has been made quite a bit more understandable (it makes way
    more sense to call "render_children()" on the input container!) and some
    weird special handling for nested arrays (that didn't work correctly
    anyway) has been removed.

commit a7883eccfd1565937f4712a671d0ebae1a847eeb
Author: Dave Gauer 
Date:   Sat Dec 14 18:52:58 2024 -0500

    Re-minify and added minification shell script

commit e7ecae0c0797c3019686456ce9159dc993fab338
Author: Hector Dearman 
Date:   Mon Mar 4 21:41:13 2024 +0000

    Clear oncreate callbacks on each render
    
    Signed-off-by: Dave Gauer 

commit cf0473f2ae776367130b7e17614fee25db43a693
Author: Dave Gauer 
Date:   Sat Dec 14 18:40:35 2024 -0500

    Updated demo with link to website

commit 98993c20ea80b5113de6d66f42fef9f86b574e59
Author: Dave Gauer 
Date:   Sat Dec 14 18:34:23 2024 -0500

    Updated README

commit 5a3150b97c5eeeb62ed85b7177dfd9e705e1c5dc
Author: Dave Gauer 
Date:   Sat Dec 14 18:31:53 2024 -0500

    Added rvid special property, demo/doc, and test
    
    Also added Crockford's jsmin.c to do minifying locally with no
    external dependencies.

commit b5aa0c7562987f6688f59c378051ce6a912cbd7e
Author: Dave Gauer 
Date:   Mon Dec 4 21:14:56 2023 -0500

    Added textarea update example

commit fc3aaaa49ce4799434c4c681033922df435f0fdc
Author: Dave Gauer 
Date:   Fri Sep 29 21:06:02 2023 -0400

    Updated README with 'rat-flavored' markdown :-)
    
    RepoRat uses 'discount' for a very pure md conversion.

commit 8057ea4e838332aeea85f42e6644a64e8978c211
Author: Dave Gauer 
Date:   Fri Aug 18 14:30:29 2023 -0400

    Updated minified source with list bugfix

commit fa9f6dd45cbf9bddc299d0e23d99df217221328d
Author: Dave Gauer 
Date:   Fri Aug 18 14:26:04 2023 -0400

    Fixed bug replacing tag with list
    
    It would fail to remove original tag before appending list items.

commit 6832a5a24600307a82f81239a00686ad0f879f47
Author: Dave Gauer 
Date:   Fri Apr 7 16:17:03 2023 -0400

    Fixed bug when null or undefined "updates" to same

commit beda634923a111bba89eeb10ed5fff987cc2770e
Author: Dave Gauer 
Date:   Fri Apr 7 13:12:59 2023 -0400

    Allow also 'undefined' value placeholders

commit f8892e14046990f0cb521c075ba811cc48e0ebdd
Author: Dave Gauer 
Date:   Wed Apr 5 13:06:12 2023 -0400

    Fix bad properties object check - null is an 'object'!
    
    Also updated min file with this and last fix

commit 2d418084d0e2c5ad3ec5001b68747bc5c3c46522
Author: Dave Gauer 
Date:   Wed Apr 5 12:33:36 2023 -0400

    Fix non-empty container render error
    
    We need to clear non-empty containers on their first render
    or the DOM child indexing will be forever wrong and updates
    will crash.
    
    Also added a (hopefully never needed) diagnostic error message
    to the console if update() encounters a dom_elem that doesn't
    exist again. I presume this would happen if manual changes are
    made to the DOM outside RetroV.

commit 3ada5fcd081a7f28dd278bf35a0e58d7bd24a529
Author: Dave Gauer 
Date:   Wed Mar 29 08:25:46 2023 -0400

    Fix wording in demo/tutorial

commit 87f41e53aafb955056580cea0f39ea4842b352e8
Author: Dave Gauer 
Date:   Tue Mar 28 18:03:50 2023 -0400

    Raw HTML elements + demo and tests

commit 28a003db87c2176cffb2c1b487e88debc2377ebc
Author: Dave Gauer 
Date:   Sun Mar 26 19:02:47 2023 -0400

    Tweak readme

commit ff20842828c1fe9c0529e4ffa8ac0b6e916c8890
Author: Dave Gauer 
Date:   Sun Mar 26 13:35:09 2023 -0400

    Refactored a bit, updated min

commit f91319591383846f3fb84928804eb95fd557df17
Author: Dave Gauer 
Date:   Sun Mar 26 11:22:45 2023 -0400

    Added oncreate event

commit a3db654b8fcd60bb89b0623a1f57c79c57c61d19
Author: Dave Gauer 
Date:   Sat Mar 25 14:51:48 2023 -0400

    Updated .min and README

commit 1a77c1d4889a3ba30b0a840b26f6c2d689cf4f4b
Author: Dave Gauer 
Date:   Sat Mar 25 14:48:27 2023 -0400

    Special handling for checkbox/radio checked property

commit 91291550026ee9130b2d7b2e37f0a9232af3c8e8
Author: Dave Gauer 
Date:   Sat Mar 25 11:42:24 2023 -0400

    Special input value handling

commit 9b242afcb5fe974909adbffbf363af7aa09cb41b
Author: Dave Gauer 
Date:   Sat Mar 25 09:24:51 2023 -0400

    Updated .min and test.html now tests it too

commit 389b8b8e30cd3299e0aab0cd400fae8e87d35c2b
Merge: 7bb1427 e77f6ce
Author: Dave Gauer 
Date:   Sat Mar 25 08:42:26 2023 -0400

    Merge branch 'main' of github.com:ratfactor/retrov

commit 7bb1427f11ea7adaaeb15bbf7b6791a778516648
Author: Dave Gauer 
Date:   Sat Mar 25 08:42:06 2023 -0400

    Special handling of 'for' label property

commit e77f6ce7d2903f55f300f90c8045d9e3becbe29e
Author: Dave Gauer 
Date:   Fri Mar 24 20:56:57 2023 -0400

    Fix demo wording

commit bbbf4a44537a07e160e1db24731accd241431c1c
Author: Dave Gauer 
Date:   Fri Mar 24 20:54:45 2023 -0400

    Added minified release

commit fa92aa72ac2ba20e474b24b0ab948033840f0d4b
Author: Dave Gauer 
Date:   Thu Mar 23 20:43:56 2023 -0400

    Oops, demo.html tweak lol

commit 77b69deeb9999017c8be595dab62ae16a95a9c6e
Author: Dave Gauer 
Date:   Thu Mar 23 20:36:40 2023 -0400

    Cleaning up demo.html
    
    Had help from the best little proof-reader around. :-)

commit fb5c627abea83430c3c2cde6a1d0a3652c976f4f
Author: Dave Gauer 
Date:   Thu Mar 23 19:52:39 2023 -0400

    fix Readme

commit c5674d75cdc15ac3a3f27cd737ee8a4a9b921123
Author: Dave Gauer 
Date:   Thu Mar 23 19:39:27 2023 -0400

    VDOM diffing fully functional!
    
    Three re-writes later.

commit 3642e647e72bf7ac78056450ca6ea34fe8ff51b3
Author: Dave Gauer 
Date:   Mon Mar 13 11:52:42 2023 -0400

    README links point to base of repos

commit 8e1a03fb637c871adba7dd42b7016a0cce04f629
Merge: 9d672ae dd6fc74
Author: Dave Gauer 
Date:   Mon Mar 13 11:50:40 2023 -0400

    Merge branch 'main' of github.com:ratfactor/retrov

commit 9d672ae2291ddcbe52fe65a62ceeb4e54539da42
Author: Dave Gauer 
Date:   Mon Mar 13 11:50:06 2023 -0400

    Added example to README

commit ae562976eca4602395f1c342a2d76ff3e3b34d56
Author: Dave Gauer 
Date:   Mon Mar 13 11:42:08 2023 -0400

    Added handling for arrays of elements

commit dd6fc74381e17175e383e5bac709a8895bdc7cd4
Author: Dave Gauer 
Date:   Mon Mar 13 09:13:47 2023 -0400

    README - I will never enjoy Markdown link syntax

commit c747662f2506f743c2ac5efd240b2f1931ffebff
Author: Dave Gauer 
Date:   Mon Mar 13 09:08:09 2023 -0400

    Sorting out how diffing might work

commit df0252d85b7a296750ef08361ab1e664f0670ac6
Author: Dave Gauer 
Date:   Mon Mar 13 08:49:51 2023 -0400

    Initial commit - rendering from data works
    
    Does not do diffing yet, so it probably wouldn't work with text input
    fields. Otherwise, surprisingly useful already.