diff options
| author | Ariel D'Alessandro <dalessandro.ariel@gmail.com> | 2021-11-25 00:05:34 +0100 |
|---|---|---|
| committer | Ariel D'Alessandro <dalessandro.ariel@gmail.com> | 2021-11-25 00:05:59 +0100 |
| commit | 412f51cd7ad4ce610ecaf13210b52709fb3e0232 (patch) | |
| tree | bf6475830cc0df42b671bf7ce9a1b33fe70f0e37 /lua/alpha/snippets/config.lua | |
| parent | 31efe743072b868d4bb86ed709b85253db0b1f60 (diff) | |
| download | nvim-conf-412f51cd7ad4ce610ecaf13210b52709fb3e0232.tar.gz nvim-conf-412f51cd7ad4ce610ecaf13210b52709fb3e0232.zip | |
Move config to lua. Add laravel snippets
Diffstat (limited to 'lua/alpha/snippets/config.lua')
| -rw-r--r-- | lua/alpha/snippets/config.lua | 34 |
1 files changed, 34 insertions, 0 deletions
diff --git a/lua/alpha/snippets/config.lua b/lua/alpha/snippets/config.lua new file mode 100644 index 0000000..ff438c2 --- /dev/null +++ b/lua/alpha/snippets/config.lua @@ -0,0 +1,34 @@ +local ls = require"luasnip" +local s = ls.snippet +local sn = ls.snippet_node +local t = ls.text_node +local i = ls.insert_node +local f = ls.function_node +local c = ls.choice_node +local d = ls.dynamic_node +-- local types = require("luasnip.util.types") + +-- Every unspecified option will be set to the default. +ls.config.set_config({ + history = true, + -- Update more often, :h events for more info. + updateevents = "TextChanged,TextChangedI", + -- ext_opts = { + -- [types.choiceNode] = { + -- active = { + -- virt_text = { { "choiceNode", "Comment" } }, + -- }, + -- }, + -- }, + -- treesitter-hl has 100, use something higher (default is 200). + ext_base_prio = 300, + -- minimal increase in priority. + ext_prio_increase = 1, + enable_autosnippets = true, +}) + +-- ls.snippets = { +-- php = require('alpha.snippets.php') +-- } + +vim.api.nvim_set_keymap("i", "<c-k>", "<Plug>luasnip-expand-or-jump", {}) |