LuaSnip icon indicating copy to clipboard operation
LuaSnip copied to clipboard

vim-snippets snipmate like snippets does not expand iterpolation

Open voyeg3r opened this issue 3 years ago • 1 comments

I was able to set the path to the vim-snippets and load them like this:

require("luasnip.loaders.from_snipmate").load({
  paths = {
    vim.fn.stdpath('config') .. '/snippets',
  }
})

But the snippet "date", wich is:

snippet date
	`strftime("%Y-%m-%d")`

does not expand the date. What I am doing wrong?

If is not a feature yet, could it be someday?

voyeg3r avatar Feb 06 '22 14:02 voyeg3r

You're doing nothing wrong, it just isn't supported yet.

If is not a feature yet, could it be someday?

definitely :D

L3MON4D3 avatar Feb 06 '22 14:02 L3MON4D3

soooooooooooooooooooooo, with the current master it should work automatically for snippets loaded via loaders.from_snipmate. ls.parser.parse_snipmate can be used otherwise.

L3MON4D3 avatar Aug 27 '22 18:08 L3MON4D3