Closed mwawrusch closed 9 years ago
Seems to relate to michaelficarra/CoffeeScriptRedux#308 which describes the same problem in the redux parser.
I'm afraid until the issue linked above is resolved, the best workaround is
content: [
{
a: 'a value'
b: 'b value'
c:
d: 'nested d'
}
{
a: 'a value'
b: 'b value'
}
]
(Alternatively the the separator can be }, {
)
thanks jan, i just realized that. It's good enough for me. Great work, btw.
On Sat, May 24, 2014 at 9:36 AM, Jan Krems notifications@github.com wrote:
I'm afraid until the issue linked above is resolved, the best workaround is
content: [ { a: 'a value' b: 'b value' c: d: 'nested d' } { a: 'a value' b: 'b value' } ]
(Alternatively the the separator can be }, {)
— Reply to this email directly or view it on GitHubhttps://github.com/groupon/cson-safe/issues/5#issuecomment-44092537 .
Is there any plan to support this? Seems it worked well in cson, see bevry/cson#37
Unfortunately this is a restriction of the redux parser, it will be hard to support this without changes to redux itself. cson
builds on top of coffee-script 1.x which behaves the same often but not always. So far it seemed like everyone's happy to just use the wrapping curly braces, so addressing this didn't seem high priority. Especially since the curly-less style seems to degenerate into ASCII art pretty quickly and I'm not sure if it's all that valuable to enable it. ;) But a PR to redux might be successful and I'd happily bump the version in here once it has landed.
We are switching to coffee-script 1.x for parsing. So - hurray! - this'll work now as expected.
hi guys, first of all apologies for not writing tests, I am under some severe time constraints right now.
I noticed, when using grunt-cson, which is based on this module, that the following valid coffeescript does not get parsed:
It breaks on the ','. I use a temporary (ugly) workaround, but wanted to let you know.