AstroNvim / astrocommunity

A community repository of common plugin specifications
GNU General Public License v3.0
1.13k stars 233 forks source link

Use new `optional` option where applicable #213

Closed mehalter closed 1 year ago

mehalter commented 1 year ago

Lazy.nvim recently added a new optional option that should make it easier to have plugins that configure other plugins only if they are available elsewhere. Should make it easier to make plugins that have interoperability with other plugins but you don't want to assume the user has it installed. It would be nice for us to use that wherever necessary

https://github.com/folke/lazy.nvim/commit/9177778891ecdf02562eeaa1a26b829e4b62bc16

luxus commented 1 year ago

to clarify here a example if i get it right: https://github.com/AstroNvim/astrocommunity/tree/main/lua/astrocommunity/colorscheme/nord-nvim nord could add bufferline and headline to the code, but the plugins will not get loaded until they are loaded somewhere else because they are optional

mehalter commented 1 year ago

Here is an example of using this appropriately: https://github.com/AstroNvim/astrocommunity/pull/217