js function name code example
Example 1: js call function by string name
function test() {
console.log('Executed function "test".');
}
window['test']();
Example 2: javascript function name
function WriteSomeShitOut(){
var a = new Error().stack.match(/at (.*?) /);
console.log(a[1]);
}
WriteSomeShitOut();