MCPcopy Create free account
hub / github.com/Roy3838/Observer / onModelsChange

Method onModelsChange

app/src/utils/ModelManager.ts:716–721  ·  view source on GitHub ↗

* Subscribe to model list changes

(listener: (models: Model[]) => void)

Source from the content-addressed store, hash-verified

714 * Subscribe to model list changes
715 */
716 public onModelsChange(listener: (models: Model[]) => void): () => void {
717 this.listeners.push(listener);
718 return () => {
719 this.listeners = this.listeners.filter(l => l !== listener);
720 };
721 }
722
723 private notifyListeners(): void {
724 const models = this.listModels().models;

Callers 3

MCPFunction · 0.80
ModelLocationIndicatorFunction · 0.80
StaticAgentViewFunction · 0.80

Calls 1

pushMethod · 0.80

Tested by

no test coverage detected