api-blueprint-sublime-plugin
api-blueprint-sublime-plugin copied to clipboard
Incorrect highlighting when MSON attribute description contains underscore
Same problem here with wrong rendering
+ Request Client credentials (application/json)
+ Attributes
+ grant_type: `client_credentials` (string, required)
+ client_id: `88888888-4444-4444-4444-cccccccccccc` (string, required)
+ client_secret: `clientsecret` (string, required)
+ Body
{
"grant_type": "client_credentials",
"client_id": "88888888-4444-4444-4444-cccccccccccc",
"client_secret": "clientsecret"
}

@danielgtaylor Now that I look at this with fresh eyes, this might not be an issue at all, since underscores in MSON are not allowed and they need to be escaped. If that rule is followed, the highlighter would not make any mistake.
MSON are not allowed and they need to be escaped
This is true for property names and values. Not for description.
Same hightlighting issue happens if you have a JSON payload that contains a key that starts with an underscore.
For instance:
## Videos Collection [/videos]
Provides access to all videos.
+ Model (application/json)
JSON representation of videos
+ Body
{
"_pagination":
{
"next": "/videos?offset=7",
"total_count": 100
}
}
Highlighting is incorrect in sublime text starting from the underscore.
any update?