https://github.com/thomas-hiron/cmp-twig-templates
nvim-cmp source for Twig templates autocompletion
https://github.com/thomas-hiron/cmp-twig-templates
neovim neovim-plugin neovim-plugin-lua nvim-cmp
Last synced: 7 months ago
JSON representation
nvim-cmp source for Twig templates autocompletion
- Host: GitHub
- URL: https://github.com/thomas-hiron/cmp-twig-templates
- Owner: thomas-hiron
- License: mit
- Created: 2025-02-15T14:19:57.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2025-02-15T14:28:30.000Z (over 1 year ago)
- Last Synced: 2025-02-15T15:30:10.623Z (over 1 year ago)
- Topics: neovim, neovim-plugin, neovim-plugin-lua, nvim-cmp
- Language: Lua
- Homepage:
- Size: 2.93 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# cmp-twig-templates
[nvim-cmp](https://github.com/hrsh7th/nvim-cmp) source for twig templates
located in project directory /templates.
[FD](https://github.com/sharkdp/fd) is a required dependency.
Templates are refreshed every 30 seconds.
## Setup
```lua
require('cmp').setup({
sources = {
{ name = 'twig_templates' },
},
})
```
## Triggers
The plugin is activated for `php` and `twig` filetypes.
The trigger character is a single quote, and the line must contains
`render` or `include`. This covers most of Symfony and twig
functions used to generate URLs:
- PHP
- render
- renderView
- Twig
- include
## Configuration
There is no configuration at the moment.