Skip to content

Support to change the key from the variable name #84

@krishna-kashyap

Description

@krishna-kashyap

Currently JSON.NET uses JsonProperty attribute to provide the different values for keys other than variable names. Could something similar be possible with NetJSON as well?

For eg:

public class SimpleObj

{
    public string name { get; set; }
    public string email  { get; set; }
}

This I'd like to make into a JSON as

{
    "name": "ABCD",
    "mail_address": "[email protected]"
}

Metadata

Metadata

Assignees

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions