feat: support mini.completion
Neovim version (nvim -v)
nvim nightly
Feature Description
Hi! Is it possible to support mini.completion as the completion plugin with nvim-html-css?
Use Case / Motivation
I use the mini.nvim suite of plugins and hence use mini.completion for completion along with mini.snippets for integration which works really well for me. Is there any chance this plugin can work with mini.completion?
Alternatives
None
Additional Information
N/A
I have checked the src code of mini completion and here is what i have found, as I can see there is no support for extra sources, it's basically like builtin autocomplete with ability to define custom snippets.
I have checked the src code of mini completion and here is what i have found, as I can see there is no support for extra sources, it's basically like builtin autocomplete with ability to define custom snippets.
It supports a fallback for omnifunc, if a omnifunc implementation can be provided by this plugin, we can make use of it to get it working.
@Jezda1337 another way to do this is to create ### an in memory lsp server which can serve completions like how mini.snippets or render-markdown.nvim plugins do this.
@Jezda1337 another way to do this is to create ### an in memory lsp server which can serve completions like how mini.snippets or render-markdown.nvim plugins do this.
I like the idea of a simple, minimalist LSP server it shouldn't be too hard to implement. I just need some time to explore the topic. I'm currently very busy, but I hope to find some time over the next couple of weeks to look into it. Thanks for bringing up the idea!
@231tr0n I've added a basic LSP solution to the /dev branch. Could you give it a try? I've tested it with Neovim's built-in autocompletion, and it seems to be working fine.
@Jezda1337 I have called the setup method but the lsp seems to not be up for html files. Is this config correct?
add({
source = "Jezda1337/nvim-html-css",
checkout = "dev",
monitor = "dev",
})
require("html-css").setup({
enable_on = { "html" },
handlers = {
definition = {
bind = "gd",
},
hover = {
bind = "K",
wrap = true,
border = "none",
position = "cursor",
},
},
documentation = {
auto_show = true,
},
style_sheets = {},
}
sry i forgot to mention:
lsp = {
enable = true,
},
this is in the same lvl as handlers, neable_on, style_sheet
@Jezda1337 It works now! Thank you for considering my request and implementing it!
@231tr0n Sure, thanks for the suggestions. I'll keep this on the dev branch for now since it still needs more testing. Once I have time to properly test it, I'll go ahead and merge it into main. Hopefully, I can get to some thorough testing soon. Cheers!
@231tr0n Sure, thanks for the suggestions. I'll keep this on the dev branch for now since it still needs more testing. Once I have time to properly test it, I'll go ahead and merge it into main. Hopefully, I can get to some thorough testing soon. Cheers!
Yup will sit next week and integrate this properly into my mini.nvim config.
@Jezda1337 will this be merged this weekend? I am planning on spending my time working on my neovim config and taught I will noicely integrate this as well.
@231tr0n probably not this weekend, got a ton of stuff on over the next couple of weeks. I’ll try to get to it before the end of the month though