I don’t really see the point of this? Snap! already has native JSON parsing, with split [] by [json v] and [json V] of @list
Unless you use a user-created JSON parser, there is no way to tell the difference without using strings, between
[
["a", "foo"],
["b", "bar"],
["c", "baz"]
]
and
{
"a": "foo",
"b": "bar",
"c": "baz"
}
it’s just javascript mostly. I can’t tell you how to improve it in snap because it’s for another programming language :~|
(EDIT: yes I know some JS and the stuff there isn’t that complex but we want to include newer users)
cause, you know,
no as in, i can’t make the command based changer work, like i need something like this
(get variable [a v]::variables)
so i could do
// x is a variable name
set (x :: variables) to ((get variable [x v] :: variables)\[(attribute :: variables)\] = (value :: variables) :: #770000)
edit: i made it work using the Create Variables library
I think you replied to the wrong person.
i didn’t know…
But, you don’t need to?