Skip to content

Commit dd4d5be

Browse files
authored
Update README.md
1 parent d788672 commit dd4d5be

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

Diff for: docs/04-js/README.md

+1
Original file line numberDiff line numberDiff line change
@@ -375,6 +375,7 @@ Let’s recap:
375375
- We created functions to group our code into reusable blocks.
376376
- We manipulated the DOM to interact with our HTML elements.
377377
- We handled events to respond to user actions.
378+
- We used closures to maintain access to important variables, enabling our drag-and-drop functionality to work correctly by keeping track of the mouse and element positions even after the initial function has executed.
378379

379380
By combining all these concepts, we created a dynamic and interactive virtual terrarium where the plants can be dragged around the screen.
380381

0 commit comments

Comments
 (0)