-
Notifications
You must be signed in to change notification settings - Fork 196
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support for .elm files #84
Comments
I second this request! |
Not exactly the same thing but I'd like to be able to use this with purescript-halogen. Just being able to specify a regex would be the best solution (I think) |
Probably related to tailwindlabs/tailwindcss#7553 |
Until this issue or tailwindlabs/tailwindcss#7553 is resolved, you might want to try the fork at https://github.com/ibirrer/tailwindcss-intellisense/releases/tag/0.4.3-elm |
I think this is covered by tailwindlabs/tailwindcss#7553 as @ibirrer said. You can enable completions in the example you provided with these settings:
See my recent comment over on tailwindlabs/tailwindcss#7553 for more info |
I’ve added a couple more regex patterns to my configuration to also support completions when using |
For whoever is trying this out in Plug 'neovim/nvim-lspconfig'
Plug 'williamboman/nvim-lsp-installer' and then lua << EOF
require("nvim-lsp-installer").setup({
ensure_installed = { "tailwindcss" }
})
require('lspconfig').tailwindcss.setup{
filetypes = { "html", "elm" },
init_options = {
userLanguages = {
elm = "html",
html = "html"
}
},
settings = {
tailwindCSS = {
includeLanguages = {
elm = "html",
html = "html"
},
classAttributes = { "class", "className", "classList", "ngClass" },
experimental = {
classRegex = {
"\\bclass[\\s(<|]+\"([^\"]*)\"",
"\\bclass[\\s(]+\"[^\"]*\"[\\s+]+\"([^\"]*)\"",
"\\bclass[\\s<|]+\"[^\"]*\"\\s*\\+{2}\\s*\" ([^\"]*)\"",
"\\bclass[\\s<|]+\"[^\"]*\"\\s*\\+{2}\\s*\" [^\"]*\"\\s*\\+{2}\\s*\" ([^\"]*)\"",
"\\bclass[\\s<|]+\"[^\"]*\"\\s*\\+{2}\\s*\" [^\"]*\"\\s*\\+{2}\\s*\" [^\"]*\"\\s*\\+{2}\\s*\" ([^\"]*)\"",
"\\bclassList[\\s\\[\\(]+\"([^\"]*)\"",
"\\bclassList[\\s\\[\\(]+\"[^\"]*\",\\s[^\\)]+\\)[\\s\\[\\(,]+\"([^\"]*)\"",
"\\bclassList[\\s\\[\\(]+\"[^\"]*\",\\s[^\\)]+\\)[\\s\\[\\(,]+\"[^\"]*\",\\s[^\\)]+\\)[\\s\\[\\(,]+\"([^\"]*)\""
}
},
lint = {
cssConflict = "warning",
invalidApply = "error",
invalidConfigPath = "error",
invalidScreen = "error",
invalidTailwindDirective = "error",
invalidVariant = "error",
recommendedVariantOrder = "warning"
},
validate = true
}
}
}
EOF |
Does anyone have a working config for intellij? |
It would be awesome if this extensions also would support elm-lang.
Elm files use css classes like so :
The text was updated successfully, but these errors were encountered: