feat: adding some comments

This commit is contained in:
kozhuhds
2025-12-05 16:06:50 +01:00
parent 4ac7e78030
commit d0042b990e
2 changed files with 4 additions and 3 deletions
@@ -419,8 +419,6 @@ export type PluginExtensionCommandPaletteDynamicConfig = {
/**
* Search provider function that returns results.
* Return an empty array to skip results for the current search.
* To conditionally disable the provider, simply return an empty array
* based on your own logic instead of using a separate isActive filter.
*/
searchProvider: CommandPaletteDynamicSearchProvider;
};
@@ -73,7 +73,10 @@ export class CommandPaletteDynamicRegistry {
continue;
}
// Use index to differentiate multiple providers from same plugin
// Use index to differentiate multiple providers from same plugin.
// Note: Provider IDs are index-based, so changing the order of configs
// in addCommandPaletteDynamicProvider calls could affect result tracking.
// Plugins should maintain consistent ordering of their providers.
const providerId = `${pluginId}/${index}`;
if (!(providerId in registry)) {