Skip to content

Latest commit

 

History

History
20 lines (15 loc) · 345 Bytes

function.tostring.md

File metadata and controls

20 lines (15 loc) · 345 Bytes

Function.toString()

  • function source code를 string 형태로 반환
function sayHello(text) {
    var name = text;
    // print name
    console.log(`Hello ${name}`);
}

console.log(sayHello.toString());

// function sayHello(text) {
//    var name = text;
//    // print name
//    console.log(`Hello ${name}`);
// }