-
Notifications
You must be signed in to change notification settings - Fork 1
regex for sanitising is invalid #4
Comments
Why would you create such a weird identifier :P. But yes, point taken. Caml is being reworked from the ground up to properly parse such exotic constructions (branch parser). |
To hijack the issue: sanitize is too eager. Using comments after a property causes the property to dissapear, e.g.
Results in
Property |
Yes, the sanitizer is overly aggressive. For now a workaround is to make sure your comments are on a dedicated line. |
I've parked the parser for now, without proper documentation of yaml-js (connec/yaml-js#12) I simply do not have the time to rework this from the ground up for now. @asgoth could you log this into a new issue? This might still be tackled in the current regex based setup. |
Just use this one, no? Edit: or you mean about the comments? |
I believe the original issue here was already solved in #7 (by explicitly disallowing nested quotes in object keys. |
Alright, will close this one, I'll rise another issue from this one's ashes. Closed by #7 |
Regex
/[",'].*\..*[",']:/
matches stuff like the following yaml file incorrectly:In yaml:
In caml:
The text was updated successfully, but these errors were encountered: