MCPcopy Create free account
hub / github.com/Exafunction/codeium-chrome / setStorageData

Function setStorageData

src/storage.ts:61–71  ·  view source on GitHub ↗
(data: Storage)

Source from the content-addressed store, hash-verified

59}
60
61export function setStorageData(data: Storage): Promise<void> {
62 return new Promise((resolve, reject) => {
63 chrome.storage.sync.set(data, () => {
64 if (chrome.runtime.lastError) {
65 return reject(chrome.runtime.lastError);
66 }
67
68 return resolve();
69 });
70 });
71}
72
73export function getStorageItem<Key extends keyof Storage>(key: Key): Promise<Storage[Key]> {
74 return new Promise((resolve, reject) => {

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected