Urara-Blog/node_modules/.pnpm-store/v3/files/8b/a1fd02d4aab5da59b06e4ce81355ef46e47347cd35888754bbe9424c20ed24d849db463a0a72bc7789d60828b20ed97b0ff1ae2b4f32b74d7b58d412a0d08a
2022-08-14 01:14:53 +08:00

30 lines
1.1 KiB
Text

import { BuildResult, InjectManifestOptions } from './types';
/**
* This method creates a list of URLs to precache, referred to as a "precache
* manifest", based on the options you provide.
*
* The manifest is injected into the `swSrc` file, and the placeholder string
* `injectionPoint` determines where in the file the manifest should go.
*
* The final service worker file, with the manifest injected, is written to
* disk at `swDest`.
*
* This method will not compile or bundle your `swSrc` file; it just handles
* injecting the manifest.
*
* ```
* // The following lists some common options; see the rest of the documentation
* // for the full set of options and defaults.
* const {count, size, warnings} = await injectManifest({
* dontCacheBustURLsMatching: [new RegExp('...')],
* globDirectory: '...',
* globPatterns: ['...', '...'],
* maximumFileSizeToCacheInBytes: ...,
* swDest: '...',
* swSrc: '...',
* });
* ```
*
* @memberof workbox-build
*/
export declare function injectManifest(config: InjectManifestOptions): Promise<BuildResult>;