It is possible to JSON::getProperty("Root.child.subchild.another.value") with a long path?


It is possible to get a property with a long path using JSON::getProperty("") ?

For example:

    "Synth": {
        "Keyboard": {
            "Key": {
                "Color": [255, 255, 170, 1.0]

At the moment I’m doing this this way:

static Array<var>* getArray(var *json, const String& path) {
            StringArray arr;
            arr.addTokens(path, ".", "\"");
            auto object = *json;
            for (auto &s : arr) {
                object = object.getProperty(s, var());
            return object.getArray();

Are you using your JsonLoader class as a global or static object somewhere?

1 Like

No, I don’t use any static objects in the app.

My apologies just found a stupid issue. I didn’t deleted my JsonLoader class in the parent object.
Anyway I have another question (Will change in a topic)