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

Method mark

packages/svelte/src/internal/client/reactivity/batch.js:530–549  ·  view source on GitHub ↗
(value)

Source from the content-addressed store, hash-verified

528 * @param {Value} value
529 */
530 const mark = (value) => {
531 var reactions = value.reactions;
532 if (reactions === null) return;
533
534 for (const reaction of reactions) {
535 var flags = reaction.f;
536
537 if ((flags & DERIVED) !== 0) {
538 mark(/** @type {Derived} */ (reaction));
539 } else {
540 var effect = /** @type {Effect} */ (reaction);
541
542 if (flags & (ASYNC | BLOCK_EFFECT) && !this.async_deriveds.has(effect)) {
543 this.#maybe_dirty_effects.delete(effect);
544 set_signal_status(effect, DIRTY);
545 this.schedule(effect);
546 }
547 }
548 }
549 };
550
551 for (const source of this.current.keys()) {
552 mark(source);

Callers

nothing calls this directly

Calls 4

scheduleMethod · 0.95
set_signal_statusFunction · 0.90
hasMethod · 0.45
deleteMethod · 0.45

Tested by

no test coverage detected