Documentation
    Preparing search index...

    Function createNotifyService

    • Create a NAP-NOTIFY service backed by host-owned notification behavior.

      A backendless instance is safe to register for conformance testing: send requests return an error and permission requests return granted: false instead of manufacturing successful delivery.

      Parameters

      Returns ServiceHandler

      Runtime service handler for the notify domain.

      const notify = createNotifyService({
      present: ({ message }) => showToast(message.title, message.body),
      requestPermission: () => promptUser(),
      });
      runtime.registerService('notify', notify);