ChemPal Documentation - v1.18.0
    Preparing search index...

    Function isPriceAlertKey

    • Whether a storage key holds a price alert, for change listeners.

      Parameters

      • key: string

        The storage key

      Returns boolean

      True for an alert's key

      isPriceAlertKey('price_alert:3f9c2a'); // true
      isPriceAlertKey('user_settings'); // false
      export function isPriceAlertKey(key: string): boolean {
      return key.startsWith(priceAlertKey(''));
      }