CtrlK
CommunityDocumentationLog inGet started
Tessl Logo

tessl/npm-workbox-webpack-plugin

tessl install tessl/npm-workbox-webpack-plugin@7.3.0

A plugin for your Webpack build process, helping you generate a manifest of local files that workbox-sw should precache.

Agent Success

Agent success rate when using this tile

80%

Improvement

Agent success rate improvement when using this tile compared to baseline

1.19x

Baseline

Agent success rate without this tile

67%

task.mdevals/scenario-4/

Service Worker Output Compatibility

Ensure the service worker build setup handles output paths and build-time reporting reliably across webpack environments.

Capabilities

Resolves destination relative to output path

  • Provided webpack output path /app/dist and destination /tmp/custom-sw.js, the emitted service worker ends up under dist/custom-sw.js without writing to /tmp. @test

Chooses compatible build hooks

  • With a compiler exposing a modern asset-processing stage, the plugin is applied through that hook; with only legacy emit hooks available, it falls back without warnings. @test

Logs manifest summary

  • After precache manifest generation, a log entry includes the service worker filename, number of entries, and total bytes cached. @test

Implementation

@generates

API

export interface SwBuildOptions {
  swSrc?: string;
  swDest: string;
  logLevel?: "summary" | "silent";
}

export function attachServiceWorkerBuild(
  compiler: import("webpack").Compiler,
  options: SwBuildOptions
): void;

Dependencies { .dependencies }

workbox-webpack-plugin { .dependency }

Integrates service worker generation into webpack builds, including manifest creation and build-time logging.

Version

Workspace
tessl
Visibility
Public
Created
Last updated
Describes
npmpkg:npm/workbox-webpack-plugin@7.3.x
tile.json