MCPcopy Create free account
hub / github.com/21st-dev/1code / atomWithWindowStorage

Function atomWithWindowStorage

src/renderer/lib/window-storage.ts:128–139  ·  view source on GitHub ↗
(
  key: string,
  initialValue: T,
  options?: { getOnInit?: boolean }
)

Source from the content-addressed store, hash-verified

126 * )
127 */
128export function atomWithWindowStorage<T>(
129 key: string,
130 initialValue: T,
131 options?: { getOnInit?: boolean }
132) {
133 return atomWithStorage<T>(
134 key,
135 initialValue,
136 createWindowScopedStorage<T>(),
137 options
138 )
139}

Callers 3

atoms.tsFile · 0.90
index.tsFile · 0.90
index.tsFile · 0.90

Calls 1

Tested by

no test coverage detected