Compare commits

..
4 Commits
Author SHA1 Message Date
github-actions[bot] a30af4423c chore: bump version to 0.21.6 2026-03-12 20:08:34 +00:00
Frederic CabassutandClaude Opus 4.6 deca26931e fix: block service worker in e2e tests to prevent response interception
Active service workers change the fetch lifecycle enough that Playwright's
waitForResponse() misses SW-mediated responses, causing preferences tests
to timeout. Block SW registration during e2e tests.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-12 21:08:20 +01:00
github-actions[bot] 335b01f60e chore: bump version to 0.21.5 2026-03-12 20:01:20 +00:00
Frederic CabassutandClaude Opus 4.6 ba1ddd4489 fix: restrict SW API caching to GET requests to avoid intercepting mutations
Workbox route matching intercepts all HTTP methods, which caused PUT/POST
requests (e.g. preferences updates) to be handled by the SW strategy
handler instead of passing through directly. Restrict API and attachment
cache rules to GET-only using function-based urlPattern.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-12 21:00:56 +01:00
4 changed files with 9 additions and 5 deletions
+1 -1
View File
@@ -1,7 +1,7 @@
{
"name": "crumbs",
"private": true,
"version": "0.21.4",
"version": "0.21.6",
"type": "module",
"license": "MIT",
"author": "Bretzel (https://bretzel.app)",
+2 -1
View File
@@ -11,7 +11,8 @@ export default defineConfig({
use: {
baseURL: 'http://localhost:4173',
trace: 'on-first-retry',
screenshot: 'only-on-failure'
screenshot: 'only-on-failure',
serviceWorkers: 'block'
},
projects: [
{
+5 -2
View File
@@ -52,7 +52,9 @@ export default defineConfig({
}
},
{
urlPattern: /\/api\/notes\/.*\/attachments\?attachmentId=/,
urlPattern: ({ request, url }) =>
request.method === 'GET' &&
/\/api\/notes\/.*\/attachments\?attachmentId=/.test(url.href),
handler: 'CacheFirst',
options: {
cacheName: 'attachment-cache',
@@ -60,7 +62,8 @@ export default defineConfig({
}
},
{
urlPattern: /^https?:\/\/.*\/api\//,
urlPattern: ({ request, url }) =>
request.method === 'GET' && /\/api\//.test(url.pathname),
handler: 'NetworkFirst',
options: {
cacheName: 'api-cache',
+1 -1
View File
@@ -280,7 +280,7 @@
<li><a href="https://github.com/bretzel-app/crumbs/blob/main/docs/DEPLOYMENT.md" target="_blank" rel="noopener">Docs</a></li>
<li><a href="https://github.com/bretzel-app/crumbs/blob/main/LICENSE" target="_blank" rel="noopener">License</a></li>
</ul>
<span class="footer-version">v0.21.4</span>
<span class="footer-version">v0.21.6</span>
</div>
</footer>