Closed willcrichton closed 1 year ago
Thanks! I believe the crux of this issue was improper string formatting when assigning JavaScript values to HTML attributes. I've updated the Living Papers runtime to use JSON.stringify
on object values. This update is included in version 0.1.6 (just released). Hopefully this resolves the issue for you. If not, please let us know!
Also, as you are not using any external dependencies, your custom element can subclass ArticleElement
instead. (This will of course be clearer once we have proper documentation in place...)
That fixed my issue. At last, I can write down my shopping list :-)
Enjoy your omelet!
I'm trying to write a component that turns a list of strings into a bulleted list. Something like:
I have implemented a custom component like this:
However, the syntax and semantics of array parameters seems very flaky? I see that the
option-text
component uses a numeric array input that seems to work. But all of the following seem to bring up issues:Where "issues" means either the program fails to parse, or the array gets stringified weirdly and the component has a
null
value forthis.items
.Is there a better approach to what I'm trying to do?