Skip to content
Discussion options

You must be logged in to vote

optionalPlugins could also be called lazyPlugins but the nvim terminology they use in the manual is "optional"

It simply means that they are added to the rtp under pack/myNeovimPackages/opt/<name> rather than pack/myNeovimPackages/start/<name>.

Plugins in start are loaded immediately on startup. If they have files in their plugin/* directory they will be ran, ftplugin files will be taken care of, etc.

Plugins in opt are not loaded immediately. You instead must call vim.cmd.packadd("<name>") to load them

If you call vim.cmd.packadd during your initial init.lua's run, that plugin will be loaded just like it was in start

If you call vim.cmd.packadd any time after that, it will load the thing…

Replies: 1 comment 1 reply

Comment options

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

Answer selected by JBlocklove
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