Good morning, question about SVG support. I see that the supported elements are listed in Om's src/main/om/dom.cljc
. If I wanted to use an element that is not on the list, foreignObject
, should that be as simple as adding the element to the vector and adding a set of attrs to the supported-attrs below? In other words, are these lists merely whitelists of known working elements, or do they each represent work done somewhere else, say, in React?
it's mostly a white-list
if you can't find a tag there, you can create the element with: (js/React.createElement "anytag" #js {:attr "value"} "children")
before react 16, react did blacklist some attributes (not tags), but since 16 they stopped doind that
Excellent, that would be a good place to start experimenting. Thanks for the sitrep 🙂
no problem 😉