MarcosLopezC / LightJson

A simple JSON library for C#.
MIT License
60 stars 21 forks source link

Tests, better handling of POCOs, a couple attributes #40

Closed thegoldenmule closed 6 years ago

thegoldenmule commented 6 years ago

Hi there,

I needed a few random things, so I added them-- don't know if you're interested.

var value = new MyObject();
var json = new JsonObject(value).ToString();
[JsonIgnore]
public int Foo;

The field "Foo" will be ignored in JsonObject.

public class Foo
{
    [JsonName("fizz")]
    public int Bar;
}

Outputs to roughly { "fizz" : 3 } for example.

MarcosLopezC commented 6 years ago

@thegoldenmule

Thank you for this contribution. However, there are some changes that I want to make to the API before I merge it back into master.

thegoldenmule commented 6 years ago

Great, look forward to seeing them.