Values and Expressions

Discover the power of JavaScript, the core technology of the web, bringing interactivity and dynamic behaviour to websites

Meher Howji avatar image
··· Likes

Values and expressions are an interesting concept. It leads our way to understanding JS slightly better. And this is because JS has its inspirations from languages like Scheme and Lisp and it helps learn about JS from a very different lens.

A value in JS is something that you give to the JS engine and you get back the same value. e.g.

console.log(42) // you get 42 back from JS
console.log("hello") // you get "hello" back from JS

And all values are expressions too not vice versa.