Jeffail/gabs

generating json

Closed this issue · 1 comments

@Jeffail thanks for this package, very easy to use. just having problem after getting all keys i need how to generate new json from sample below. could you maybe provide some snippet if possible

{
    "name": "sample",
    "def": [{
        "setId": 1,
        "setDef": [{
            "name": "ABC",
            "type": "STRING",
            "property": {
                "field1": "text1",
                "field2": "text2"
            }
        }, {
            "name": "XYZ",
            "type": "STRING",
            "property": {
                "field1": "text1",
                "field2": "text2"
            }
        }]
    }, {
        "setId": 2,
        "setDef": [{
            "name": "abc",
            "type": "STRING",
            "property": {
                "field1": "text1",
                "field2": "text2"
            }
        }, {
            "name": "xyz",
            "type": "STRING",
            "property": {
                "field1": "text1",
                "field2": "text2"
            }
        }]
    }]
}

Hey @vokary, what would your desired output be from this example?