且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

Json.Net布尔解析问题

更新时间:2023-01-17 19:37:51

我不想添加此技巧来更改保存时的大小写,但是 有更好的方法来处理这种情况.

I dont want to add this hack to change the case when saving but is there a better way to handle this scenario.

否,如果希望以后可以使用JSON序列化程序(例如Newtonsoft JSON)反序列化,则保存时必须产生有效的JSON.因此,修正保存的路由是正确的方法.

No, you have to produce valid JSON when saving if you want to be able to later deserialize it with a JSON serializer such as Newtonsoft JSON. So fixing your saving routing is the right way to go here.