notational-fzf-vim
notational-fzf-vim copied to clipboard
Add pre- and post-hooks for integration with other plugins
This PR adds two events User#NVEnter
and User#NVLeave
to enable integration with other plugins such as junegunn/goyo.vim and junegunn/limelight.vim.
I received an email asking for more information on wiring this plugin and Goyo together, so I'll reproduce here some of my .vimrc.
call plug#begin()
" Writing
Plug 'junegunn/goyo.vim'
Plug 'junegunn/limelight.vim'
Plug 'junegunn/fzf', { 'dir': '~/.fzf', 'do': './install --all' }
Plug 'https://github.com/sverona/notational-fzf-vim', { 'branch': 'pre-post-hook' }
" ...
call plug#end()
autocmd! User NVLeave Goyo
autocmd! User GoyoEnter Limelight
autocmd! User GoyoLeave Limelight!
" ...
let mapleader = '\'
nnoremap <leader>z :NV<CR>
This is a nice addition. +1