JsonSerializerSwift
JsonSerializerSwift copied to clipboard
Multi-dimentional Arrays
Hi @peheje,
I added this to my local to handle Multi-dimentional Arrays.
else if let array = value as? [[Any]] {
handledValue += "["
for (index, value) in array.enumerated() {
handledValue += "\(value)"
handledValue += (index < array.count-1 ? ", " : "")
}
handledValue += "]"
}
Cool! Maybe we could create a unit test for this and pull it into master?
hi
i am trying this but i am getting extra {} in jsonString
{[{"WebAddress": "http://yahoo.com", "State": "1"}]}
it should generate
[{"WebAddress": "Asdadsad", "State": "1"}]
I think recent commit 5ae566790a4066d1392dc2d7fc24d9ae70c040d8 might have fixed that. If you post the test I can try to fit it in there. Would appreciate it!