doc: setup call is only allowed once

This commit is contained in:
Alexander Courtis
2022-06-04 12:37:02 +10:00
parent a0f705995a
commit 3aeb59b075
2 changed files with 6 additions and 0 deletions

View File

@@ -33,8 +33,11 @@ use {
## Setup
Setup should be run in a lua file or in a lua heredoc (`:help lua-heredoc`) if using in a vim file.
Legacy `g:` options have been migrated to the setup function. See [this issue](https://github.com/kyazdani42/nvim-tree.lua/issues/674) for information on migrating your configuration.
Setup may only be run once; subsequent calls will result in a warning. Do not invoke from, say, a packer config function and then call it again later.
```vim
" vimrc
nnoremap <C-n> :NvimTreeToggle<CR>