Skip to content

feat: add storage metadata watchers#2445

Open
cookesan wants to merge 2 commits into
wxt-dev:mainfrom
cookesan:watch-storage-meta
Open

feat: add storage metadata watchers#2445
cookesan wants to merge 2 commits into
wxt-dev:mainfrom
cookesan:watch-storage-meta

Conversation

@cookesan

Copy link
Copy Markdown
Contributor

Summary

  • add storage.watchMeta and item.watchMeta for listening to metadata changes without using the internal metadata key
  • normalize removed metadata to {} so watcher callbacks match getMeta
  • document the new APIs and cover storage areas plus defined items in tests

Tests

  • bun run --filter @wxt-dev/storage test index.test.ts
  • bun run --filter @wxt-dev/storage check
  • bun run --filter @wxt-dev/storage build
  • bun run docs:build
  • bun run check
  • bunx prettier --check docs/storage.md packages/storage/src/index.ts packages/storage/src/__tests__/index.test.ts
  • git diff --check

Fixes #1988

@netlify

netlify Bot commented Jun 28, 2026

Copy link
Copy Markdown

Deploy Preview for creative-fairy-df92c4 ready!

Name Link
🔨 Latest commit b2a499d
🔍 Latest deploy log https://app.netlify.com/projects/creative-fairy-df92c4/deploys/6a51299716e6410008220cba
😎 Deploy Preview https://deploy-preview-2445--creative-fairy-df92c4.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.
🤖 Make changes Run an agent on this branch

To edit notification comments on pull requests, go to your Netlify project configuration.

@github-actions github-actions Bot added the pkg/storage Includes changes to the `packages/storage` directory label Jun 28, 2026
Comment thread packages/storage/src/index.ts Outdated
@cookesan cookesan requested a review from nishu-murmu as a code owner July 10, 2026 17:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

pkg/storage Includes changes to the `packages/storage` directory

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[FEAT] support watch meta change in storage

2 participants