Skip to main content

Runtime - Service Worker

Declare Service Worker globals for JavaScript and TypeScript lifecycle code, including the worker-specific event and cache APIs supplied by that environment.

Usage

eslint.config.mts
ts
import {
  dxCodeStyle,
  dxIgnore,
  langTypescript,
  runtimeServiceWorker,
} from '@cbnventures/nova/presets/eslint';

export default [
  ...dxIgnore,
  ...dxCodeStyle,
  ...langTypescript,
  ...runtimeServiceWorker,
];

What This Preset Configures

The preset applies the globals package's Service Worker environment to JavaScript, TypeScript, MJS, and MTS files. It does not add browser-window or Node.js globals.