文章詳情頁
javascript - 關于一些文檔語法表示‘[,’
瀏覽:113日期:2023-09-10 10:21:42
問題描述
1.經常看文檔會看到一些示例語法但是看不懂語法里參數表示形式,都用參數用 ‘[,’隔開是什么意思,如下圖:
問題解答
回答1:[ ]里面的是可選參數,可以提供,也可以不提供。寫的格式是這樣的,首先 arg1,arg2, 然后arg2為可選參數,就在參數arg2上加方括號。即,arg1[,arg2]
回答2:可選參數
array.forEach(callback) 或者 array.forEach(callback, thisArg)
回答3:可選參數,就是可填可不填
標簽:
JavaScript
相關文章:
1. 網頁爬蟲 - python3.4.1 request模塊報錯 ’list’ object has no attribute ’get’2. python - 啟動Eric6時報錯:’qscintilla_zh_CN’ could not be loaded3. linux - python ImportError: No module named ’***’4. python - 為什么match匹配出來的結果是<_sre.SRE_Match object; span=(0, 54), match=’’>5. python - (2006, ’MySQL server has gone away’)6. dict - Python中dic寫入txt報錯:a bytes-like object is required, not ’str’7. python - "AttributeError: ’dict’ object has no attribute ’filename’"8. 問題Unknown column ’’ in ’where clause’9. 致命錯誤: Class ’appfacadeTest’ not found10. $_GET[’page’] 是哪兒來的?
排行榜
