Opened 16 years ago
Closed 15 years ago
#1889 closed defect (fixed)
dojo.json.serailize does not produce YAML compatible JSON
Reported by: | guest | Owned by: | Dustin Machi |
---|---|---|---|
Priority: | high | Milestone: | 0.9 |
Component: | Data | Version: | 0.4 |
Keywords: | Cc: | ||
Blocked By: | Blocking: |
Description
JSON is nearly a strict subset of YAML (and this is by design at this point http://ajaxian.com/archives/json-yaml-its-getting-closer-to-truth ). One sticky point is that YAML requires spaces after , and : in the object notation (due to it's grammar). It would be nice if this was at least an option for dojo.json.serialize(). Ideally, it would just be done that way always, but I could imagine someone will want to have the more compact form. Other than hacking the source, it can't easily be done done because arrays are intercepted before the Adapter registry is examined. Fix requires using ", " in the array loop and ", " and ": " in the object loop.
rbunker at tableausoftware.com
Change History (2)
comment:1 Changed 15 years ago by
Milestone: | → 0.9 |
---|---|
Owner: | changed from skinner to Dustin Machi |
comment:2 Changed 15 years ago by
Resolution: | → fixed |
---|---|
Status: | new → closed |
(In [8992]) update json serializer to produce yaml compliant output. also fixed dependent xhr test. fixes #1889