api-blueprint
                                
                                 api-blueprint copied to clipboard
                                
                                    api-blueprint copied to clipboard
                            
                            
                            
                        Improve UX around MSON reserved characters
There have been many issues reported by users who have forgotten to escape reserved characters. This even catches people working on the parser for MSON itself https://github.com/apiaryio/snowcrash/issues/338 (myself included).
We should find a way to improve the experience around this, either with improved warnings in the parser (snowcrash) or improved MSON documentation making this clearer.
:+1: On Jun 10, 2015 7:17 PM, "Kyle Fuller" [email protected] wrote:
There have been many issues reported by users who have forgotten to escape reserved characters. This even catches people working on the parser for MSON itself #338 (myself included).
We should find a way to improve the experience around this, either with improved warnings in the parser (snowcrash) or improved MSON documentation making this clearer.
— Reply to this email directly or view it on GitHub https://github.com/apiaryio/api-blueprint/issues/210.
:+1:
:+1:
If anyone has any suggestions on how to improve the experience around the reserved characters please let me know.
@kylef how does actually currently parser decides when the attribute name ends?
When it sees a colon or a hyphen or an open parentheses.
@pksunkara I don't think that's entirely true given underscores can break it as well.
Underscore doesn't stop the parsing, it searches for the second underscore and treats the whole thing as a markdown italic.
+ name_a: b gives name_a
+ name_a_: b gives name_a_
+ name_a: b_ gives name_a: b_ which is probably not the users' intention.
@pksunkara so Markdown parsing happens before structural parsing?
Yes. It's also related to Variable Property Name a bit. If you look at the example there, you can see why I want to give preference to _ & *.