We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent a829155 commit 83d2003Copy full SHA for 83d2003
1-js/04-object-basics/04-object-methods/8-chain-calls/task.md
@@ -28,12 +28,14 @@ ladder.up();
28
ladder.up();
29
ladder.down();
30
ladder.showStep(); // 1
31
+ladder.down();
32
+ladder.showStep(); // 0
33
```
34
35
Modify the code of `up`, `down` and `showStep` to make the calls chainable, like this:
36
37
```js
-ladder.up().up().down().showStep(); // 1
38
+ladder.up().up().down().showStep().down().showStep(); // shows 1 then 0
39
40
41
Such approach is widely used across JavaScript libraries.
0 commit comments