Skip to content

Commit

Permalink
Add note in README detailing how to add dash to Vim's 'word' definiti…
Browse files Browse the repository at this point in the history
…on in markdown files (#101)
  • Loading branch information
SidOfc committed May 17, 2020
1 parent 5fe100e commit 645f2fc
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -530,6 +530,18 @@ Given text `Hello world` where the cursor can be anywhere inside the first word
<kbd>2</kbd>+<kbd>[\<PREFIX\>](#gmkdxsettingsmapprefix)</kbd><kbd>b</kbd> will
wrap both `Hello` and `world`: `**Hello world**`. This works for all the mappings above.

**NOTE:** mkdx wraps using Vim's 'word' (`:h word`), sometimes 'word' will not include command
characters such as `-` which means mkdx may fail to wrap `hello-world` as one word.
To fix this the `iskeyword` option can be overridden to include `-` or any other character:

```viml
augroup markdown
autocmd!
" Include dash in 'word'
autocmd FileType markdown setlocal iskeyword+=-
augroup END
```

## Convert CSV to table (and back)

![mkdx convert csv to table](doc/gifs/vim-mkdx-tableize.gif)
Expand Down

0 comments on commit 645f2fc

Please sign in to comment.