Open kyoshino opened 9 years ago
It might be better to use comments instead of data-*
attributes. NodeIterator
allows us to iterate over comments like this, so <!-- if cf_user_story -->
<!-- else -->
<!-- endif -->
can be found easily and the markup won't get messed up.
let iter = document.createNodeIterator(document.body, NodeFilter.SHOW_COMMENT); iter.nextNode()
See also IE's conditional comments
See also: XSLT elements, including if
and for-each
FlareTail.js only has a simple
fill
method that renders Microdata (usually Schema.org). It would be nice to have support ofif-else
switches orfor
loops, so we can hide something (see https://github.com/bzdeck/bzdeck/pull/281) or iterate over items.Should we use template strings?
Also, the view should be automatically updated once the data has been changed. We need
Object.observe
becauseObject.watch
andProxy
are bad for performance, but no one is working on the new method...