Compare commits

...

3 Commits

Author SHA1 Message Date
62db4b3054 ci: add nvim 0.9.5 to test against
Closes #176
2024-05-21 14:22:18 -05:00
57daea0208 docs: add section about lazy loading to README
Closes #178
2024-05-21 14:17:46 -05:00
796fbadfcf chore: remove loose/unused file 2024-05-21 14:16:22 -05:00
3 changed files with 10 additions and 48 deletions

View File

@ -14,6 +14,10 @@ jobs:
url: https://github.com/neovim/neovim/releases/download/v0.10.0/nvim-linux64.tar.gz
manager: sudo apt-get
packages: -y fd-find tree-sitter-cli
- os: ubuntu-24.04
url: https://github.com/neovim/neovim/releases/download/v0.9.5/nvim-linux64.tar.gz
manager: sudo apt-get
packages: -y fd-find tree-sitter-cli
steps:
- uses: actions/checkout@v3
- run: date +%F > todays-date

View File

@ -59,6 +59,12 @@ require('nvim-ts-autotag').setup({
> If you are setting up via `nvim-treesitter.configs` it has been deprecated! Please migrate to the
> new way. It will be removed in `1.0.0`.
### A note on lazy loading
For those of you using lazy loading through a plugin manager (like [lazy.nvim](https://github.com/folke/lazy.nvim)) lazy
loading is not particularly necessary for this plugin. `nvim-ts-autotag` is efficient in choosing when it needs to load.
If you still insist on lazy loading `nvim-ts-autotag`, then two good events to use are `BufReadPre` & `BufNewFile`.
### Extending the default config
Let's say that there's a language that `nvim-ts-autotag` doesn't currently support and you'd like to support it in your

View File

@ -1,48 +0,0 @@
set rtp +=.
set rtp +=../plenary.nvim/
set rtp +=../nvim-treesitter/
set rtp +=../playground/
set rtp +=../nvim-treesitter-rescript/
runtime! plugin/plenary.vim
runtime! plugin/nvim-treesitter.lua
runtime! plugin/nvim-treesitter-playground.lua
runtime! plugin/nvim-treesitter-rescript.vim
set noswapfile
set nobackup
filetype indent off
set nowritebackup
set noautoindent
set nocindent
set nosmartindent
set indentexpr=
set foldlevel=9999
lua << EOF
_G.__is_log=true
_G.ts_filetypes = {
'html', 'javascript', 'typescript', 'svelte', 'vue', 'tsx', 'php', 'glimmer', 'rescript', 'embedded_template'
}
require("nvim-treesitter.configs").setup({
ensure_installed = _G.ts_filetypes,
highlight = { enable = true },
sync_install = true
})
vim.treesitter.language.register('tsx', 'typescriptreact')
vim.treesitter.language.register('embedded_template', 'eruby')
require("plenary/busted")
vim.cmd[[luafile ./tests/test-utils.lua]]
require("nvim-ts-autotag").setup({
enable = true,
enable_rename = true,
enable_close = true,
enable_close_on_slash = true,
})
EOF