typeofの読み方

typeofの読み方

javascriptで利用される演算子の1つである「typeof」の読み方を掲載してます。

読み⽅

タイプオブ」と読みます。

typeofとは

javascriptで、変数の型を判定する際に使用する演算子となります。

  var str = '123.456';
  console.log( typeof str ); // string
  var result = Number(str);  // 数値型に変更
  console.log( typeof result ); // number