JavaScript was created in 1995 as a simple language exclusively for web browsers, to "make web pages alive". Since then it has greatly evolved, it's quite far from there it started.
There's a formal language description called [ECMAScript Language Specification](https://tc39.es/ecma262/), it describes how a JavaScript engine works. Sometimes we'll give references to it, but, though technically correct, it's hard to read for humans.
Also, there's a good JavaScript reference at [MDN](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference). One can type `mdn <a javascript term>` in an internet search engine to find the information about that term there.