mirror of
https://github.com/LazyVim/LazyVim.git
synced 2026-07-25 14:01:06 +00:00
fix(extra-lang-angular): implement @folke suggestion for fixing angular treesitter
This commit is contained in:
parent
86811ad7aa
commit
11ce94e185
1 changed files with 5 additions and 6 deletions
|
|
@ -14,13 +14,12 @@ return {
|
||||||
if type(opts.ensure_installed) == "table" then
|
if type(opts.ensure_installed) == "table" then
|
||||||
vim.list_extend(opts.ensure_installed, { "angular", "scss" })
|
vim.list_extend(opts.ensure_installed, { "angular", "scss" })
|
||||||
end
|
end
|
||||||
vim.filetype.add({
|
vim.api.nvim_create_autocmd("BufRead", {
|
||||||
pattern = {
|
pattern = { "*.component.html", "*.container.html" },
|
||||||
[".*%.component%.html"] = "angular.html",
|
callback = function()
|
||||||
[".*%.container%.html"] = "angular.html",
|
vim.treesitter.start(nil, "angular")
|
||||||
},
|
end,
|
||||||
})
|
})
|
||||||
vim.treesitter.language.register("angular", "angular.html")
|
|
||||||
end,
|
end,
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue