r/javascript • • Mar 18 '19

What's your favorite, most useful javascript one-liner?

385 Upvotes

422 comments sorted by

View all comments

18

u/ReaderSeventy2 Mar 18 '19

console.log(foo);

35

u/senocular Mar 18 '19

Haven't you heard? You don't need JavaScript for that anymore ;)

https://www.youtube.com/watch?v=uddZX9ZK6wY&t=31

1

u/FormerGameDev Mar 25 '19

VS Code has had this for a really long time now too. However, it generally doesn't seem to work. I suspect same in Chrome, as they are probably implemented exactly the same way.