From 8e4083cb017b95c25a0676c019a6a11f95ca1746 Mon Sep 17 00:00:00 2001 From: ayoayco Date: Fri, 16 Aug 2024 08:14:39 +0200 Subject: [PATCH] chore: add todo --- index.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/index.js b/index.js index 718f8e2..491f924 100644 --- a/index.js +++ b/index.js @@ -134,6 +134,10 @@ export default function serviceWorker(config) { const versionDeclaration = `const __version = ${JSON.stringify(assetCacheVersionID)};\n`; const prefixDeclaration = `const __prefix = ${JSON.stringify(assetCachePrefix)};\n`; + /** + * TODO: allow importing in dev's sw.js by resolving imports + */ + await writeFile( outFile, assetsDeclaration + versionDeclaration + prefixDeclaration + originalScript