How to get native javascript functions source code?

  1. Pick a browser
  2. Make sure it is an open source one
  3. Dig through its source code

Some repositories include:

  • Firefox
  • Webkit
  • Chromium

Note that JavaScript native functions are generally not written in JavaScript (expect C or C++ most of the time). They are just exposed to JS through an API.

Also note that the code that scrolls a page when the spacebar is pressed isn’t even a function that is exposed to JS.

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)