Lazy loading dependencies #372
-
|
I've added Overseer to my setup, and it auto-detects telescope as a picker for menus. However, it doesn't know telescope exists until I trigger telescope in some other way first, so I get a fallback picker built in native Instead, I'd like to ensure that telescope is loaded before overseer. Is this something I should do in overseer's spec with |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 3 replies
-
|
Assuming you are using lze for lazy loading, you would set dep_of will load the spec it is on after that other plugins There is also So in the telescope spec you would put If the other thing does indeed |
Beta Was this translation helpful? Give feedback.
Assuming you are using lze for lazy loading, you would set
dep_ofto load before theloadhook, of the other spec, which by default is what calls packadd, loading the plugin.dep_of will load the spec it is on after that other plugins
beforehook and before itsloadhook.There is also
on_pluginto load after theloadhook but before theafterhook.So in the telescope spec you would put
dep_of = { "theotherone" }If the other thing does indeed
requiretelescope however, instead of dep_of you could puton_require = "telescope"and lze will load the spec in which that is set whenever some submodule oftelescopeis required and fails to load (via a custom package.loaders entry it adds at s…