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
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.
Related
- Pair it with the matching Runtime - Service Worker TSConfig preset.
- Review the layering order in ESLint Best Practices.