Closed oscarotero closed 1 year ago
It's not just about comments the same odd behavior can also be observed with just newlines:
> parse('\n')
undefined
> parse('\n\n')
null
I guess this can be closed now that #3442 has been merged? (thanks btw!)
Describe the bug
This issue comes up here: https://github.com/lumeland/lume/pull/431#issuecomment-1578393330
Parsing an empty string returns
undefined
, but a string with only a comment, returnsnull
.There's a relevant issue in the js-yaml library.
Steps to Reproduce
Run the following in REPL mode:
Expected behavior
I'd expect to return always
undefined
in all cases (ornull
if you prefer, but not both).Environment