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

Method oncommit

packages/svelte/src/internal/client/reactivity/batch.js:839–841  ·  view source on GitHub ↗

@param {(batch: Batch) => void} fn

(fn)

Source from the content-addressed store, hash-verified

837
838 /** @param {(batch: Batch) => void} fn */
839 oncommit(fn) {
840 this.#commit_callbacks.add(fn);
841 }
842
843 /** @param {(batch: Batch) => void} fn */
844 ondiscard(fn) {

Callers 4

#mergeMethod · 0.95
ensureMethod · 0.80
eachFunction · 0.80
errorMethod · 0.80

Calls 1

addMethod · 0.45

Tested by

no test coverage detected