Skip to content

Better handling for nested JSON #1

@bocklucas

Description

@bocklucas

Current Behavior

The script does not handle nested JSON well (It will create another class with the same name)

Desired Behavior

Create dynamic names, perhaps referencing the parent class? Or some kind of better naming convention.

Example

DeleteRecipt.cs
{
...
"data": {
    "data": {
      "deleteRecipt": {
        "ok": true
      }
    }
  }
}

will result in

    [Serializable]
    public class DataObjectResponse
    {
       public DeletereciptObjectResponse deleteRecipt;
    }

    [Serializable]
    public class DataObjectResponse
    {
       public DataObjectResponse data;
    }

    [Serializable]
    public class DeletereciptObjectResponse
    {
       public ErrorsObjectResponse[] errors;
       public DataObjectResponse data;
    }

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions