编程语言/命名:修订间差异
来自康健生活
| 第18行: | 第18行: | ||
==== 构造函数命名 ==== | ==== 构造函数命名 ==== | ||
构造函数首字母应该{{underline|大| | 构造函数首字母应该{{underline|大|blue}}写。 | ||
<syntaxhighlight lang="javascript"> | <syntaxhighlight lang="javascript"> | ||
var nowDate = new DateFormat(); // DateFormat is a constructor function.</syntaxhighlight> | var nowDate = new DateFormat(); // DateFormat is a constructor function.</syntaxhighlight> | ||