How does MVC asp.net serialization work for Json object on Controller actions ?
For example I have a custom object and if send an ajax request with JSON objects to the server action
public ActionResult(List<CustomObject> abc)
{
// Object is serialized automatically how MVC is doing it is the question.
}
The reason why I am asking this is that some objects of mine are not properly serialzed and hence loss of data is there , then I have to revert to the old method of string value to serializaiton.
public ActionResult(string abc)
{
JavaScriptSerializer serializer = new JavaScriptSerializer();
List<CustomObject> lstabc = serializer.Deserialize<List<CustomObject>>(abc);
}
Which I would like to avoid and secondly which are the best libraries for doing JSON object serialization MVC Asp.net ?