HakonHarnes / img-clip.nvim

Effortlessly embed images into any markup language, like LaTeX, Markdown or Typst
MIT License
443 stars 7 forks source link

feat: arguments in template function #28

Closed HakonHarnes closed 7 months ago

HakonHarnes commented 7 months ago

Related issue

Closes #26.

Summary of changes

Passes the following args to the template function:

local template_args = {
  file_path = file_path,
  file_name = file_name,
  file_name_no_ext = file_name_no_ext,
  cursor = "$CURSOR",
  label = label,
}
lervag commented 7 months ago

The latest version is very good, thanks! I believe this way of doing it should bring more or less full flexibility to the user.