You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
For those working with and writing APIs, the removal of fromJSON and toJSON would be catastrophic. I have even suggest the addition of toXML and fromXML. Do not forget there was a huge push for REST in MODX.
It would certainly be a breaking change which requires deprecating it before removing to make sure people currently using it are notified before it's actualy gone...
... but how is it catastrophic when json_encode and json_decode are equivalent and have been widely supported for like a decade? A basic find and replace could update a codebase in like 30 seconds.
Catastrophic is an overstatement, I admit. From an API developer standpoint having the output data types closest to the raw data is the best -- especially as databases have a native json fieldtype. I will make changes on my two year old xpdo3 applications.
Activity
wshawn commentedon Feb 7, 2022
For those working with and writing APIs, the removal of fromJSON and toJSON would be catastrophic. I have even suggest the addition of toXML and fromXML. Do not forget there was a huge push for REST in MODX.
Mark-H commentedon Feb 7, 2022
It would certainly be a breaking change which requires deprecating it before removing to make sure people currently using it are notified before it's actualy gone...
... but how is it catastrophic when
json_encodeandjson_decodeare equivalent and have been widely supported for like a decade? A basic find and replace could update a codebase in like 30 seconds.wshawn commentedon Feb 7, 2022
Catastrophic is an overstatement, I admit. From an API developer standpoint having the output data types closest to the raw data is the best -- especially as databases have a native json fieldtype. I will make changes on my two year old xpdo3 applications.