Re:How to manage HTML DOM with vanilla JavaScript only?
by mattmcknight on Thursday April 02, 2020 @11:45AM
(#22760264)
"descend into a tangle of tracking dependencies by hand."
What is your definition of "by hand"? What constitutes by hand and what does not constitute by hand?
[ Parent
| on HN ]
Re:How to manage HTML DOM with vanilla JavaScript only?
by sgustard on Thursday April 02, 2020 @05:53PM
(#22764298)
My definition is declaring each dependency explicity. "A, B and C depend on D or E." Add a watcher on D and E to go update A, B and C. Repeat for every combination of dependencies. When app is complex enough I threw that away for a framework that tracked dependencies for me.
Re:How to manage HTML DOM with vanilla JavaScript only?
by mattmcknight on Thursday April 02, 2020 @08:11PM
(#22765175)
Sorry, I don't understand. How would the framework know what the dependencies are if you don't declare them, even indirectly in some fashion? In what sense are they dependent?