diff options
Diffstat (limited to 'files/zh-cn/web/javascript/reference/global_objects/number')
-rw-r--r-- | files/zh-cn/web/javascript/reference/global_objects/number/isfinite/index.html | 6 | ||||
-rw-r--r-- | files/zh-cn/web/javascript/reference/global_objects/number/number/index.html | 4 |
2 files changed, 5 insertions, 5 deletions
diff --git a/files/zh-cn/web/javascript/reference/global_objects/number/isfinite/index.html b/files/zh-cn/web/javascript/reference/global_objects/number/isfinite/index.html index aef163cfb6..47a2ee8f0b 100644 --- a/files/zh-cn/web/javascript/reference/global_objects/number/isfinite/index.html +++ b/files/zh-cn/web/javascript/reference/global_objects/number/isfinite/index.html @@ -17,7 +17,7 @@ translation_of: Web/JavaScript/Reference/Global_Objects/Number/isFinite <h2 id="Syntax" name="Syntax">语法</h2> -<pre class="syntaxbox notranslate"><code>Number.isFinite(v<var>alue</var>)</code></pre> +<pre class="syntaxbox"><code>Number.isFinite(v<var>alue</var>)</code></pre> <h3 id="Parameters" name="Parameters">参数</h3> @@ -36,13 +36,13 @@ translation_of: Web/JavaScript/Reference/Global_Objects/Number/isFinite <h2 id="Polyfill">Polyfill</h2> -<pre class="brush: js notranslate">if (Number.isFinite === undefined) Number.isFinite = function(value) { +<pre class="brush: js">if (Number.isFinite === undefined) Number.isFinite = function(value) { return typeof value === 'number' && isFinite(value); }</pre> <h2 id="示例">示例</h2> -<pre class="brush: js notranslate">Number.isFinite(Infinity); // false +<pre class="brush: js">Number.isFinite(Infinity); // false Number.isFinite(NaN); // false Number.isFinite(-Infinity); // false diff --git a/files/zh-cn/web/javascript/reference/global_objects/number/number/index.html b/files/zh-cn/web/javascript/reference/global_objects/number/number/index.html index e539061589..604944ab1b 100644 --- a/files/zh-cn/web/javascript/reference/global_objects/number/number/index.html +++ b/files/zh-cn/web/javascript/reference/global_objects/number/number/index.html @@ -9,7 +9,7 @@ translation_of: Web/JavaScript/Reference/Global_Objects/Number/Number <h2 id="语法">语法</h2> -<pre class="brush: js notranslate">new Number(<var>value</var>) +<pre class="brush: js">new Number(<var>value</var>) </pre> <h3 id="参数">参数</h3> @@ -23,7 +23,7 @@ translation_of: Web/JavaScript/Reference/Global_Objects/Number/Number <h3 id="创建_Number_对象">创建 Number 对象</h3> -<pre class="brush: js notranslate">const a = new Number('123'); // a === 123 is false +<pre class="brush: js">const a = new Number('123'); // a === 123 is false const b = Number('123'); // b === 123 is true a instanceof Number; // is true b instanceof Number; // is false</pre> |