Added Latex snippets

This commit is contained in:
afonsofrancof 2022-10-14 15:14:23 +01:00
parent 0920366c9d
commit b9c54ea4b8
5 changed files with 44 additions and 0 deletions

View file

@ -0,0 +1,5 @@
local M = {}
M.plugins = require("custom.plugins")
return M

View file

@ -0,0 +1,3 @@
local autocmd = vim.api.nvim_create_autocmd
vim.g.luasnippets_path = "~/.config/nvim/lua/custom/luasnippets"

View file

@ -0,0 +1,17 @@
{
"Create Split": {
"prefix": ["split"],
"body": [
"\\langle $1 \\rangle$0"
],
"description": "Create a Split"
},
"Use CP Rule": {
"prefix": ["rule"],
"body": [
"\\equiv \\{Propriedade\\ ${1:Numero_da_propriedade}\\}$0"
],
"description": "Create a Split"
}
}

View file

@ -0,0 +1,11 @@
{
"name": "My Custom Snippets",
"contributes":{
"snippets":[
{
"language":["plaintex","tex"],
"path": "./languages/latex.json"
}
]
}
}

View file

@ -0,0 +1,8 @@
return {
["L3MON4D3/LuaSnip"] = {
config = function()
require("plugins.configs.others").luasnip()
require("luasnip.loaders.from_vscode").lazy_load({ paths = vim.g.luasnippets_path })
end
}
}