Chapter 1. Prototype
2055 ワード
Prototypeとは?
Prototypeの定義
Prototype=プロトタイプオブジェクト.
JSはPrototype Based Languageであり、Prototypeベースの言語である.
Prototypeを使用する理由
大まかな例

Prototype vs(下線2回)proto(下線2回)
関数とは?
function Truck() {}
PrototypeとProtoはどのように接続されていますか?
関数を作成するときに作成されます。


Truck.prototype.drive = function(){}

let oldTruck = new Truck('Lee', 'orange', 20)

例えば、

Reference
この問題について(Chapter 1. Prototype), 我々は、より多くの情報をここで見つけました https://velog.io/@dlskaghd234/Chapter-1.-Prototypeテキストは自由に共有またはコピーできます。ただし、このドキュメントのURLは参考URLとして残しておいてください。
Collection and Share based on the CC Protocol