Baseline Widely available
toString()
ã¡ã½ããã¯ãæå®ããã Boolean ãªãã¸ã§ã¯ãã表ãæååãè¿ãã¾ãã
const flag1 = new Boolean(true);
console.log(flag1.toString());
// Expected output: "true"
const flag2 = new Boolean(1);
console.log(flag2.toString());
// Expected output: "true"
æ§æ è¿å¤
æå®ããã Boolean
ãªãã¸ã§ã¯ãã表ãæååã§ãã
Boolean
ãªãã¸ã§ã¯ã㯠Object
ãªãã¸ã§ã¯ãã® toString
ã¡ã½ããã䏿¸ããã¦ããã Object.prototype.toString()
ãç¶æ¿ãã¦ãã¾ããã Boolean
ãªãã¸ã§ã¯ãã§ã¯ã toString
ã¡ã½ããã¯ãªãã¸ã§ã¯ããæååã§è¡¨ãããã®ãè¿ãã¾ãã
JavaScript 㯠toString()
ã¡ã½ãããã Boolean
ãæååå¤ã¨ãã¦è¡¨ç¾ãããã¹ãå ´åãã Boolean
ãæååã®çµåã§åç
§ãããã¨ãã«èªåçã«å¼ã³åºãã¾ãã
Boolean
ãªãã¸ã§ã¯ãã¨è«çå¤ã§ã¯ãçµã¿è¾¼ã¿ã® toString
ã¡ã½ããã¯ãã® Boolean
ãªãã¸ã§ã¯ãã®å¤ã«ãã£ã¦ "true
" ã "false
" ã®æååãè¿ãã¾ãã
toString
ã®ä½¿ç¨
以ä¸ã®ã³ã¼ãã§ã¯ãflag.toString()
㯠"true
" ãè¿ãã¾ãã
var flag = new Boolean(true);
var myVar = flag.toString();
仿§æ¸ ãã©ã¦ã¶ã¼ã®äºææ§ é¢é£æ
å ±
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4