You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
There is no way to expand it etc. Seems it is treated as simple string without object structure. If I enter my JSON code directly (as I get it when I put {{ attr.value }} in my template) it works fine and it is formatted correctly. I also made sure the JSON is valid.
I struggled with this as well, finally figured out the json-formatter expects an object, not a string. Wherever attr.value is defined, you need: attr.value = JSON.parse( json string value ); and then it will work.
My html:
<json-formatter json='attr.value' open='1'></json-formatter>
Is shown like this:
"{"globalId":"123","language":"en"}"
(in green)There is no way to expand it etc. Seems it is treated as simple string without object structure. If I enter my JSON code directly (as I get it when I put {{ attr.value }} in my template) it works fine and it is formatted correctly. I also made sure the JSON is valid.
I also tried
<json-formatter json='{{ attr.value }}' open='1'></json-formatter>
I'm clueless guys.
The text was updated successfully, but these errors were encountered: