0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 3 years have passed since last update.

javascript オブジェクト指向の備忘録

Posted at

オブジェクトの基本構造
var オブジェクト名= {
   プロパティ名: ------,
   プロパティ名: ------
}

呼び出しは
オブジェクト名.プロパティ名();

関数をオブジェクト内に組み込むことを考える
関数名 → プロパティ名

function start(){
 ーーーー
}

var object= {
start: function (){
 ーーーー
 }
}

呼び出し
object.start();

ーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーーー
Tips
関数を実行する際についての豆知識

----------= start();
はページが読み込まれた際にstart関数が実行される

----------= start;
は----------が発生する度に実行される

0
0
1

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?