From df15f9c029453117837ee3f331bd279f70c3c327 Mon Sep 17 00:00:00 2001 From: Tan Li Hau Date: Wed, 20 Apr 2022 00:16:37 +0800 Subject: [PATCH] Update site/content/docs/03-run-time.md Co-authored-by: Ignatius Bagus --- site/content/docs/03-run-time.md | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/site/content/docs/03-run-time.md b/site/content/docs/03-run-time.md index 86fc629198..b5deb4002f 100644 --- a/site/content/docs/03-run-time.md +++ b/site/content/docs/03-run-time.md @@ -578,7 +578,12 @@ const coords = spring({ x: 50, y: 50 }); // updates the value immediately coords.set({ x: 100, y: 200 }, { hard: true }); // preserves existing momentum for 1s -coords.update((target_coords, coords) => { return { x: target_coords.x, y: coords.y }; }, { soft: 1 }); +coords.update( + (target_coords, coords) => { + return { x: target_coords.x, y: coords.y }; + }, + { soft: 1 } +); ``` [See a full example on the spring tutorial.](/tutorial/spring)