I need to find out how exactly a function works, so where can i find the source code of function in Javascript ?
For example: arr.sort(function(a, b){return a-b});
this function sort() gonna sort all index of an array.
But i don't know how this function compare all the Index to each other specifically
To direct answer the question you asked, you can find function source code like this:
console.log([].sort);
or
console.log(myFunc);
This works with any function.