following up on my question the other day about components in select options, it's annoying to have to track whether a given call to my translation function is in a reactive context or not: (tr ...) vs [tr ...]. is it possible to write a custom class that acts like a [tr ...] component for rendering purposes but has a toString that just calls the translation function?
You can already use (tr ...) everywhere - it's just that any changes to the relevant data used in tr will re-render not a specific instance of [tr ...] but the whole parent component.
huh okay
for some reason i though that wasn't working but it seems i messed something up
that way, i could call (tr ...) everywhere, and it would return an object that works in both contexts