2020-04-18から1日間の記事一覧
今日はメソッドの定義の仕方を複数書く。 const hello = { method1: function(){ console.log("hello!1"); }, method2: () => { console.log("hello!2"); }, method3() { console.log("hello!3"); } } hello.method1() hello.method2() hello.method3() 出力…
今日はメソッドの定義の仕方を複数書く。 const hello = { method1: function(){ console.log("hello!1"); }, method2: () => { console.log("hello!2"); }, method3() { console.log("hello!3"); } } hello.method1() hello.method2() hello.method3() 出力…