Compare commits

..

No commits in common. "62db4b3054ec6847e5cb189b4dea452ce0c7ad7f" and "6f38e4231c34497259121a007c61a0fd2f16403e" have entirely different histories.

3 changed files with 48 additions and 10 deletions

View File

@ -14,10 +14,6 @@ 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,12 +59,6 @@ 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

48
tests/minimal.vim Normal file
View File

@ -0,0 +1,48 @@
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