vscode-markdown-shortcuts
vscode-markdown-shortcuts copied to clipboard
`.toggleItalic` failed
When I try to italicize I get this error:
'md-shortcut.toggleItalic' failed
With bold, if I use the default keymapping (ctrl b
) nothing gets bolded. Bold only seems to work if I use a custom keymap (in my case, cmd b
).
Could be related to (https://github.com/mdickin/vscode-markdown-shortcuts/issues/59)
This seems to be caused by the latest VS Code update; my work machine has version 1.40.1, whereas my home machine (where I'm seeing the problem) is on 1.41.0
I fixed this by deleting line 66 and changing line 68 in command.js:
const pattern = new RegExp('\\'+marker+'?' + wordMatch + '*'+'\\'+marker+'?');
return editorHelpers.surroundSelection(marker, marker);
I did not create a pull request because I do not know if it has broken anything. Italic now works. however.
I'm seeing this too with * as a italic marker.