From 125677594d9c1d641d6eebad98f91525f7613c1e Mon Sep 17 00:00:00 2001 From: Richard Harris Date: Sat, 9 Nov 2019 15:07:01 -0500 Subject: [PATCH] tweak wording --- .../04-updating-arrays-and-objects/text.md | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/site/content/tutorial/02-reactivity/04-updating-arrays-and-objects/text.md b/site/content/tutorial/02-reactivity/04-updating-arrays-and-objects/text.md index e637513d15..82e4c91d35 100644 --- a/site/content/tutorial/02-reactivity/04-updating-arrays-and-objects/text.md +++ b/site/content/tutorial/02-reactivity/04-updating-arrays-and-objects/text.md @@ -30,12 +30,12 @@ function addNumber() { numbers[numbers.length] = numbers.length + 1; } ``` -As a rule of thumb _The name of the reactive variable must appear on the left side of the equals to react to assignments._ -For example, this case wouldn't work: +A simple rule of thumb: the name of the updated variable must appear on the left hand side of the assignment. For example this... + ```js -const childRef = obj.foo; -childRef.bar = "new value"; +const foo = obj.foo; +foo.bar = 'baz'; ``` -And to make it work it would be needed to force an update to object with `obj = obj`. +...won't update references to `obj.foo.bar`, unless you follow it up with `obj = obj`. \ No newline at end of file