Is there a way I can goto definition (gd) when my cursor is on scss variable?
I know i can grep with telescope but that’s not what i want.
I have nvim cmp (kickstart nvim) and cssls language server installed.
Filetype is correctly recognized as scss and cssls is attached to the buffer.
Tried some cmp plugins …
Just configured "Some Saas" (this is the name of the project). GoTo definition is working but not for everything. I suspect this is due to the fact that the same variable is declared several times.
Make sure to turn off (or not to turn on) any other LSP for scss: https://wkillerud.github.io/some-sass/language-server/getting-started.html
The LSP is sutable for working with css also, so you may use "Some Saas" for .css instead of cssls.
How to configure:
npm install --global some-sass-language-server
~/.config/nvim/after/plugin/lspconfig.lua
local lspconfig = require("lspconfig")
lspconfig.somesass_ls.setup({
filetypes = { "sass", "scss", "less", "css" },
})