When using a particular file format in VS Code I noticed that this extension wasn't performing wrapping for line comments. It looks like this happened because the CustomLanguage handling that populates rewrap's config from a language-configuration.json expects the comments.lineComment field to be a string. VS Code now allows that field to be either a string or an object containing a "comment" property, like:
{
"comments": {
"lineComment": {
"comment": "//",
"noIndent": true
},
"blockComment": ["/*", "*/"]
}
}
Note: I'm not actually sure what noIndent is supposed to do, although it seems like it might be relevant for this extension. In my case the language configuration didn't actually need to use the object format, so I just changed it to use a string and confirmed that rewrap started working.
When using a particular file format in VS Code I noticed that this extension wasn't performing wrapping for line comments. It looks like this happened because the CustomLanguage handling that populates rewrap's config from a language-configuration.json expects the
comments.lineCommentfield to be a string. VS Code now allows that field to be either a string or an object containing a"comment"property, like:{ "comments": { "lineComment": { "comment": "//", "noIndent": true }, "blockComment": ["/*", "*/"] } }Note: I'm not actually sure what noIndent is supposed to do, although it seems like it might be relevant for this extension. In my case the language configuration didn't actually need to use the object format, so I just changed it to use a string and confirmed that rewrap started working.