Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@interopio/browser-worker

Package Overview
Dependencies
Maintainers
6
Versions
16
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@interopio/browser-worker

IO Connect Browser service worker module

  • 3.1.0
  • npm
  • Socket score

Version published
Weekly downloads
8
increased by14.29%
Maintainers
6
Weekly downloads
 
Created
Source

IO Connect Browser Service Worker Module

Overview

@interopio/browser-worker is a library, which is designed to be imported into a service worker file. The library enables the advanced notifications functionality of IO Connect Browser, which requires a Service Worker.

Getting Started

The package can be added to a service worker file in two ways. One is by using the importScripts() method attached to the self global object in the Service Worker scope. The library will then define and attach to the self object a number of stateless functions.

The other way is to import the package just like any other JS package in your existing service worker project. Then you can build it and the output should be a single .js file, ready to be registered as a service worker.

Usage

The library gives access to three functions:

  • self.IOWorker or default export - this function initializes the package and registers the necessary event listeners to correctly capture and process notification clicks
  • self.openBrowserPlatform or {openBrowserPlatform} - this function accepts a url and will open and wait for the platform app to be fully operational
  • self.raiseIONotification or {raiseIONotification} - this function accepts a IO Connect Browser notification settings object and will raise the notification.

Keywords

FAQs

Package last updated on 02 Nov 2023

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc