garymjr / nvim-snippets

Snippet support using native neovim snippets
MIT License
215 stars 13 forks source link

feat(cmp): use parsed snippet for cmp documentation #35

Closed folke closed 3 months ago

folke commented 3 months ago

This PR uses the parsed snippet as documentation instead of the raw snippet.

With this PR

image

Before

image

Edit: not the same snippet, but you get the idea :)

garymjr commented 3 months ago

@folke if you include utils.expand_vars in utils.preview we can catch all the variables in the preview. Otherwise the variables that nvim doesn't support are returned as empty strings.

folke commented 3 months ago

Good idea. Done!

garymjr commented 3 months ago

Thank you!