You can simply return JSON from the controller as "text/html" and then parse it on the client side using JQuery.parseJSON().
Controller:
return this.Json(
new
{
prop1 = 5,
prop2 = 10
},
"text/html");
Client side:
jsonResponse = $.parseJSON(response);
if(jsonResponse.prop1==5) {
...
}
This solution has been working for me.
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…