Web TippsAdd co-presenters in Google Meet with one click(01.09.2026 um 17:28 Uhr)
Web TippsGoogle Workspace Weekly Recap - September 4, 2026(04.09.2026 um 21:08 Uhr)
Web TippsAdd co-presenters in Google Meet with one click(01.09.2026 um 17:28 Uhr)
Web TippsGoogle Workspace Weekly Recap - September 4, 2026(04.09.2026 um 21:08 Uhr)

26 🕛 kürzlich 4 Min Lesezeit
0

I Built a Chrome Extension to Sync AI Studio System Instructions. Here's Why chrome.storage.sync Couldn't Do It

↗ Quelle (dev.to)
🗣️ Stimme:
📑 Inhaltsübersicht

I use Google AI Studio on three machines. My laptop, my desktop, and occasionally a work machine.



Every time I switched devices, my system instructions weren't there. I'd carefully crafted a "Software Architect" prompt, a "Posts & Content" persona, a "YT Expert" context — and they existed on exactly one device. The others were blank.



Chrome sync handles bookmarks, passwords, even open tabs. Why not this?






The Obvious Solution That Doesn't Work



chrome.storage.sync looks like exactly the right tool. It's built into Chrome, it syncs across devices on the same Google account, and it has a reasonable quota.



There's one catch: Chrome only syncs extension storage for extensions installed from the Chrome Web Store.



Sideloaded extensions — installed via Developer Mode from a local folder — get a randomly generated ID on each device. Different ID = different sync namespace. Your data never overlaps, even with the same Google account signed in.



I spent longer than I'd like to admit trying to work around this with a pinned manifest key field before realizing the real problem: chrome.storage.sync simply wasn't designed for this use case.






The Actual Solution: Google Drive AppData



Every Google account has a hidden Drive folder called AppData. It's invisible in the Drive UI, private to the app that created it, and accessible via the drive.appdata OAuth scope. Crucially — it works identically for sideloaded and Web Store installs, because it's keyed to your Google account, not your extension ID.



This became the sync backend.



The architecture looks like this:





  • localStorage observer (injected into AI Studio) detects saves


  • Content script relays changes to the service worker


  • Service worker owns all merge logic and Drive I/O


  • Single JSON file in Drive AppData stores the full instruction registry





Merge on pull, not replace. When device B polls Drive and finds new data, it snapshots its local state first, then merges remote into local. Items that exist locally but haven't flushed to Drive yet survive the pull instead of being clobbered.








30-Second Polling



Drive AppData has no webhooks or push notifications. Each device polls every 30 seconds, comparing the Drive file's modifiedTime against the cached value. No change = no download. An edit on device A reaches device B in 30–60 seconds depending on alarm timing.



Not instant, but good enough for the use case.






Zero Infrastructure



There's no backend server. No telemetry. No third-party calls. The extension's test suite includes a static scan that fails the build if fetch() appears in any file other than drive-client.ts.



Your instruction data lives in your own Google Drive. The drive.appdata scope gives the extension access to its own private folder only — it cannot read, modify, or touch any other file in your Drive.






Try It



Chrome Web Store:



First sync requires one manual Push Now or Pull Now to trigger the OAuth consent screen. Background sync is automatic after that.



If you've run into the same problem — or solved it differently — I'd love to hear about it in the comments.

Vollständiger Original-Bericht
Ausführliche Details, Code-Beispiele & Hersteller-Stellungnahme auf dev.to.
↗ Original-Artikel auf dev.to lesen
Wie bewertest du diesen Beitrag?
1 Klick Feedback
Teilen mit Netzwerk & Team:

Community-Analysen & Experten-Meinungen 0

Verfasse deine eigene Analyse, teile Workarounds oder diskutiere diesen Vorfall im Blog.
Noch keine Community-Analyse verfasst. Markiere einen Textabschnitt oder klicke oben auf Eigene Analyse verfassen“!
Community Pulse: Relevanz-Einschätzung
1 Klick Experten-Votum
🔴 Akute Relevanz 41%
🟡 In Evaluierung 34%
🟢 Keine Auswirkung 17%
Spannende Innovation 8%
Verwandte Story-Cluster & Quellen (Vektor-KI)
Port 8095 Engine
1 Quelle
How to evaluate LLMs before production
1 Quelle
How we make AI coding more cost efficient without sacrificing task quality
1 Quelle
Decoding the new AI lingo: Loops, harnesses, squads, hill climbing… oh my!
Ähnliche Beiträge
🔍 Verwandte News

Auch interessante Nachrichten I Built a Chrome Extension to Sync AI Studio System Instructions. Here's Why chrome.storage.sync Couldn't Do It

Thematisch verwandte Begriffe: Built, Chrome, Extension, Sync · 6 Treffer

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...