@websign/sdk - v0.1.0
    Preparing search index...

    Function onChange

    • Calls listener whenever the status may have changed: the extension announced itself (installed or updated while the page is open), or a request failed with AppMissing/AppOutdated (the app was removed or needs an update). The listener receives a fresh status; it is not called for the state at subscription time, so call status() once yourself. Returns an unsubscribe function (safe to call twice).

      Parameters

      • listener: (status: Status) => void

      Returns () => void

      const stop = onChange((s) => setReady(s.ready));