Skip to content

Commit

Permalink
improved comments
Browse files Browse the repository at this point in the history
  • Loading branch information
godzylinux committed May 17, 2024
1 parent e93918c commit 31800ee
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/svelte/src/reactivity/utils.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@ export const NOTIFY_WITH_ALL_PARAMS = Symbol();
* @template {(keyof TEntityInstance)[]} TReadProperties
* @typedef {object} Options
* @prop {TWriteProperties} write_properties - an array of property names on `TEntityInstance` that when calling a property on `TEntityInstance`, if the property name exists in this array, then mentioned property causes reactivity.
* @prop {TReadProperties} read_properties - an array of property names on `TEntityInstance` that `mutation_properties` affects
* @prop {Interceptors<TEntityInstance, TWriteProperties, TReadProperties>} [interceptors={}] - if the property names in `mutation_properties` shouldn't cause reactivity, such calling `set.add(2)` twice or accessing a property shouldn't be reactive based on some conditions, you can prevent the reactivity by returning `false` from these interceptors
* @prop {TReadProperties} read_properties - an array of property names on `TEntityInstance` that `write_properties` affect. typically used for methods when one of the parameters for that method changes because of `write_properties`. for instance `size` doesn't need to be here because it takes no parameters and is reactive based on the `version` signal.
* @prop {Interceptors<TEntityInstance, TWriteProperties, TReadProperties>} [interceptors={}] - if the property names in `write_properties` shouldn't cause reactivity, such calling `set.add(2)` twice or accessing a property shouldn't be reactive based on some conditions, you can prevent the reactivity by returning `false` from these interceptors
*/

/** @typedef {Map<string | symbol | number, Map<unknown, import("#client").Source<boolean>>>} ReadMethodsSignals */
Expand Down

0 comments on commit 31800ee

Please sign in to comment.