Open dak opened 8 years ago
Thanks for the heads up on skipNode. I'll look into what uses it brings as I'm unsure what it brings at the moment.
See this issue for a previous discussions on skip tag:
https://github.com/davidjamesstone/superviews.js/issues/10
It didn't seem to make much sense to have one.
The most obvious use case I think I've seen so far is when an element is manipulated by a 3rd party or expensive script that you don't want patch
to touch. For example, if you're using the Google Maps API and attach it to a DOM node. Without skipNode
, patch
will redraw the DOM as it was supposed to be (eg, an empty div), rather than how it should be after being manipulating by Google Maps.
Add support for the
skipNode
method in addition toskip
. See: https://github.com/google/incremental-dom/commit/ec0537be2a698f33c44565702fdb8b33b03ec724This was only added a few weeks ago and has yet to even be rolled into a release yet, so this is a bit of a preemptive request for the time being.
Additional thought: Would it be useful to add support for
skip
andskipNode
tags in addition to attributes?