Skip to content
Discussion options

You must be logged in to vote

Hey! The documentation isn't super clear about this, so we’ll probably add a note.

You want to trigger the completion menu with special characters. Some sources have default "trigger" characters, while others (like luasnip) don't. But what's cool is that you can customize it for each source.

Here’s how you can do it for your use case:

sources = {
  default = { ... },

  -- add this
  providers = {
    snippets = {
      override = {
        get_trigger_characters = function(_) return {';', '.'} end,
      },
    },
  },
},

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@odlove
Comment options

Answer selected by odlove
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants