MCPcopy
hub / github.com/sveltejs/svelte / readonly

Function readonly

packages/svelte/src/store/shared/index.js:190–195  ·  view source on GitHub ↗
(store)

Source from the content-addressed store, hash-verified

188 * @returns {Readable<T>}
189 */
190export function readonly(store) {
191 return {
192 // @ts-expect-error TODO i suspect the bind is unnecessary
193 subscribe: store.subscribe.bind(store)
194 };
195}
196
197/**
198 * Get the current value from a store by subscribing and immediately unsubscribing.

Callers 1

test.tsFile · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…