W3Cschool
恭喜您成為首批注冊(cè)用戶
獲得88經(jīng)驗(yàn)值獎(jiǎng)勵(lì)
注意:SJS 不支持 JavaScript 的大部分全局屬性和方法。
具體使用請(qǐng)參考 ES5 標(biāo)準(zhǔn)。
具體使用請(qǐng)參考 ES5 標(biāo)準(zhǔn)。
console.log 方法可在 console 窗口輸出信息,可以接受多個(gè)參數(shù),將多個(gè)參數(shù)結(jié)果連接起來輸出。
具體使用請(qǐng)參考 ES5 標(biāo)準(zhǔn)。
具體使用請(qǐng)參考 ES5 標(biāo)準(zhǔn)。
stringify(object)
: 將 object 對(duì)象轉(zhuǎn)換為 JSON 字符串,并返回該字符串。parse(string)
: 將 JSON 字符串轉(zhuǎn)化成對(duì)象,并返回該對(duì)象。console.log(undefined === JSON.stringify());
console.log(undefined === JSON.stringify(undefined));
console.log("null"===JSON.stringify(null));
console.log("222"===JSON.stringify(222));
console.log('"222"'===JSON.stringify("222"));
console.log("true"===JSON.stringify(true));
console.log(undefined===JSON.stringify(function(){}));
console.log(undefined===JSON.parse(JSON.stringify()));
console.log(undefined===JSON.parse(JSON.stringify(undefined)));
console.log(null===JSON.parse(JSON.stringify(null)));
console.log(222===JSON.parse(JSON.stringify(222)));
console.log("222"===JSON.parse(JSON.stringify("222")));
console.log(true===JSON.parse(JSON.stringify(true)));
console.log(undefined===JSON.parse(JSON.stringify(function(){})));
具體使用請(qǐng)參考 ES5 標(biāo)準(zhǔn)。
具體使用請(qǐng)參考 ES5 標(biāo)準(zhǔn)。
Copyright©2021 w3cschool編程獅|閩ICP備15016281號(hào)-3|閩公網(wǎng)安備35020302033924號(hào)
違法和不良信息舉報(bào)電話:173-0602-2364|舉報(bào)郵箱:jubao@eeedong.com
掃描二維碼
下載編程獅App
編程獅公眾號(hào)
聯(lián)系方式:
更多建議: