mirror of
https://github.com/folke/lazy.nvim.git
synced 2025-06-28 03:24:13 +00:00
docs: example specs encourage type safety with ---@type LazySpec
This commit is contained in:
parent
96584866b9
commit
9d4381fab0
1 changed files with 3 additions and 0 deletions
|
@ -156,6 +156,7 @@ When `[2]` is `nil`, then the real mapping has to be created by the `config()` f
|
|||
|
||||
```lua
|
||||
-- Example for neo-tree.nvim
|
||||
---@type LazySpec
|
||||
{
|
||||
"nvim-neo-tree/neo-tree.nvim",
|
||||
keys = {
|
||||
|
@ -196,6 +197,7 @@ version of plugins that support Semver.
|
|||
<!-- spec:start -->
|
||||
|
||||
```lua
|
||||
---@type LazySpec
|
||||
return {
|
||||
-- the colorscheme should be available when starting Neovim
|
||||
{
|
||||
|
@ -683,6 +685,7 @@ require("lazy").setup("plugins")
|
|||
- `~/.config/nvim/lua/plugins.lua` or `~/.config/nvim/lua/plugins/init.lua` **_(this file is optional)_**
|
||||
|
||||
```lua
|
||||
---@type LazySpec
|
||||
return {
|
||||
"folke/neodev.nvim",
|
||||
"folke/which-key.nvim",
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue