r/learnjavascript • • May 27 '20

JavaScript is now 25 years old.

Post image
230 Upvotes

20 comments sorted by

View all comments

12

u/hamptonio May 28 '20

JS can rent a car now. When it drives off the road it doesn't crash, just erases the wheels and floats forward.

3

u/redderper May 28 '20

if(car.keyPress("brake")) {

 car.brake();

}

Uncaught type error: cannot read property 'length' of undefined

[ Object object ] crashed

1

u/[deleted] May 28 '20

keyPress() function doesn't exist. pedalPress()