docs: Update README.md #520
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Docs: 04-updating-arrays-and-objects
Ensured clarity in the example code by defining the
obj
object. This ensures that readers understand the context and structure of the object being modified in the reactivity example.Because it is possible to trigger reactivity by referencing
foo.bar
in the template instead ofobj.foo.bar
, the following will trigger reactivity:However, the next example will not, and will require
obj = obj
reassignment:In this case,
{obj.foo.bar}
does not trigger reactivity whenfoo.bar
is updated, unlessobj
is reassigned (withobj = obj
).By including the definition of the
obj
object, we aim to elucidate the structure and context in which the reactivity example operates, ensuring a clearer understanding for the reader.