INNER CODE UNIT · JavaScript

notification

rohitg00/k8sgames · js/engine/GameEngine.js:747

    const notification = this._notifications.find((n) => n.id === id);
    if (notification) notification.read = true;
  }

  markAllNotificationsRead() {
    for (const n of this._notifications) {
      n.read = true;
    }
  }

  onRender(callback) {
    this._renderCallbacks.push(callback);
    return () => {
      this._renderCallbacks = this._renderCallbacks.filter((cb) => cb !== callback);
    };
  }

  onUpdate(callback) {

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…