From cca8027372b16df27213976106d23e74a3ea3387 Mon Sep 17 00:00:00 2001 From: ruanyf Date: Mon, 27 Sep 2021 13:00:21 +0800 Subject: [PATCH 01/45] docs(bom/navigator): edit text --- docs/bom/navigator.md | 6 +++--- docs/dom/css.md | 2 +- package-lock.json | 30 +++++++++++++++--------------- 3 files changed, 19 insertions(+), 19 deletions(-) diff --git a/docs/bom/navigator.md b/docs/bom/navigator.md index 0a92794..18476a7 100644 --- a/docs/bom/navigator.md +++ b/docs/bom/navigator.md @@ -6,7 +6,7 @@ ### Navigator.userAgent -`navigator.userAgent`属性返回浏览器的 User Agent 字符串,表示浏览器的厂商和版本信息。 +`navigator.userAgent`属性返回浏览器的 User Agent 字符串,表示用户设备信息,包含了浏览器的厂商、版本、操作系统等信息。 下面是 Chrome 浏览器的`userAgent`。 @@ -22,7 +22,7 @@ navigator.userAgent ```javascript var ua = navigator.userAgent.toLowerCase(); -if (/mobi/i.test(ua)) { +if (/mobi/.test(ua)) { // 手机浏览器 } else { // 非手机浏览器 @@ -32,7 +32,7 @@ if (/mobi/i.test(ua)) { 如果想要识别所有移动设备的浏览器,可以测试更多的特征字符串。 ```javascript -/mobi|android|touch|mini/i.test(ua) +/mobi|android|touch|mini/.test(ua) ``` ### Navigator.plugins diff --git a/docs/dom/css.md b/docs/dom/css.md index a29de76..5a1d39a 100644 --- a/docs/dom/css.md +++ b/docs/dom/css.md @@ -749,7 +749,7 @@ styleSheet.cssRules[0].conditionText ### 基本用法 -`window.matchMedia`方法用来将 CSS 的[`MediaQuery`](https://developer.mozilla.org/en-US/docs/DOM/Using_media_queries_from_code)条件语句,转换成一个 MediaQueryList 实例。 +`window.matchMedia()`方法用来将 CSS 的[`Media Query`](https://developer.mozilla.org/en-US/docs/DOM/Using_media_queries_from_code)条件语句,转换成一个 MediaQueryList 实例。 ```javascript var mdl = window.matchMedia('(min-width: 400px)'); diff --git a/package-lock.json b/package-lock.json index 9afdca7..8a03e78 100644 --- a/package-lock.json +++ b/package-lock.json @@ -92,9 +92,9 @@ "integrity": "sha512-//oorEZjL6sbPcKUaCdIGlIUeH26mgzimjBB77G6XRgnDl/L5wOnpyBGRe/Mmf5CVW3PwEBE1NjiMZ/ssFh4wA==" }, "ansi-regex": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.0.tgz", - "integrity": "sha512-bY6fj56OUQ0hU1KjFNDQuJFezqKdrAyFdIevADiqrWHwSlbmBNMHp5ak2f40Pm8JTFyM2mqxkG6ngkHO11f/lg==" + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz", + "integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==" }, "ansi-styles": { "version": "4.3.0", @@ -139,9 +139,9 @@ "integrity": "sha512-+q/t7Ekv1EDY2l6Gda6LLiX14rU9TV20Wa3ofeQmwPFZbOMo9DXrLbOjFaaclkXKWidIaopwAObQDqwWtGUjqg==" }, "balanced-match": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.0.tgz", - "integrity": "sha1-ibTRmasr7kneFk6gK4nORi1xt2c=" + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.2.tgz", + "integrity": "sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==" }, "brace-expansion": { "version": "1.1.11", @@ -460,9 +460,9 @@ } }, "find-cache-dir": { - "version": "3.3.1", - "resolved": "https://registry.npmjs.org/find-cache-dir/-/find-cache-dir-3.3.1.tgz", - "integrity": "sha512-t2GDMt3oGC/v+BMwzmllWDuJF/xcDtE5j/fCGbqDD7OLuJkj0cfh1YSA5VKPvwMeLFLNDBkwOKZ2X85jGLVftQ==", + "version": "3.3.2", + "resolved": "https://registry.npmjs.org/find-cache-dir/-/find-cache-dir-3.3.2.tgz", + "integrity": "sha512-wXZV5emFEjrridIgED11OoUKLxiYjAcqot/NJdAkOhlJ+vGzwhOAfcG5OX1jP+S0PcjEn8bdMJv+g2jwQ3Onig==", "requires": { "commondir": "^1.0.1", "make-dir": "^3.0.2", @@ -561,9 +561,9 @@ } }, "graceful-fs": { - "version": "4.2.4", - "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.4.tgz", - "integrity": "sha512-WjKPNJF79dtJAVniUlGGWHYGz2jWxT6VhN/4m1NdkbZ2nOsEF+cI1Edgql5zCRhs/VsQYRvrXctxktVXZUkixw==" + "version": "4.2.8", + "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.8.tgz", + "integrity": "sha512-qkIilPUYcNhJpd33n0GBXTB1MMPp14TxEsEs0pTrsSVucApsYzW5V+Q8Qxhik6KU3evy+qkAAowTByymK0avdg==" }, "has-flag": { "version": "4.0.0", @@ -1417,9 +1417,9 @@ "integrity": "sha512-8Y75pvTYkLJW2hWQHXxoqRgV7qb9B+9vFEtidML+7koHUFapnVJAZ6cKs+Qjz5Aw3aZWHMC6u0wJE3At+nSGwA==" }, "uglify-js": { - "version": "3.14.1", - "resolved": "https://registry.npmjs.org/uglify-js/-/uglify-js-3.14.1.tgz", - "integrity": "sha512-JhS3hmcVaXlp/xSo3PKY5R0JqKs5M3IV+exdLHW99qKvKivPO4Z8qbej6mte17SOPqAOVMjt/XGgWacnFSzM3g==" + "version": "3.14.2", + "resolved": "https://registry.npmjs.org/uglify-js/-/uglify-js-3.14.2.tgz", + "integrity": "sha512-rtPMlmcO4agTUfz10CbgJ1k6UAoXM2gWb3GoMPPZB/+/Ackf8lNWk11K4rYi2D0apgoFRLtQOZhb+/iGNJq26A==" }, "universalify": { "version": "0.1.2", From 5fd3d345454d69762958a934369e906a0ebd3dbd Mon Sep 17 00:00:00 2001 From: ruanyf Date: Mon, 4 Oct 2021 23:43:13 +0800 Subject: [PATCH 02/45] docs(bom/cookie): edit domain property --- docs/bom/cookie.md | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/docs/bom/cookie.md b/docs/bom/cookie.md index a9ba47b..80c542c 100644 --- a/docs/bom/cookie.md +++ b/docs/bom/cookie.md @@ -175,9 +175,19 @@ Set-Cookie: id=a3fWa; Expires=Wed, 21 Oct 2015 07:28:00 GMT; ### Domain,Path -`Domain`属性指定浏览器发出 HTTP 请求时,哪些域名要附带这个 Cookie。如果没有指定该属性,浏览器会默认将其设为当前域名,这时子域名将不会附带这个 Cookie。比如,`example.com`不设置 Cookie 的`domain`属性,那么`sub.example.com`将不会附带这个 Cookie。如果指定了`domain`属性,那么子域名也会附带这个 Cookie。如果服务器指定的域名不属于当前域名,浏览器会拒绝这个 Cookie。 +`Domain`属性指定 Cookie 属于哪个域名,以后浏览器向服务器发送 HTTP 请求时,通过这个属性判断是否要附带某个 Cookie。 -`Path`属性指定浏览器发出 HTTP 请求时,哪些路径要附带这个 Cookie。只要浏览器发现,`Path`属性是 HTTP 请求路径的开头一部分,就会在头信息里面带上这个 Cookie。比如,`PATH`属性是`/`,那么请求`/docs`路径也会包含该 Cookie。当然,前提是域名必须一致。 +服务器设定 Cookie 时,如果没有指定 Domain 属性,浏览器会默认将其设为浏览器的当前域名。如果当前域名是一个 IP 地址,则不得设置 Domain 属性。 + +如果指定 Domain 属性,需要遵守下面规则:Domain 属性只能是当前域名或者当前域名的上级域名,但设为上级域名时,不能设为顶级域名或公共域名。(顶级域名指的是 .com、.net 这样的域名,公共域名指的是开放给外部用户设置子域名的域名,比如 github.io。)如果不符合上面这条规则,浏览器会拒绝设置这个 Cookie。 + +举例来说,当前域名为`x.y.z.com`,那么 Domain 属性可以设为`x.y.z.com`,或者`y.z.com`,或者`z.com`,但不能设为`foo.x.y.z.com`,或者`another.domain.com`。 + +另一个例子是,当前域名为`wangdoc.github.io`,则 Domain 属性只能设为`wangdoc.github.io`,不能设为`github.io`,因为后者是一个公共域名。 + +浏览器发送 Cookie 时,Domain 属性必须与当前域名一致,或者是当前域名的上级域名(公共域名除外)。比如,Domain 属性是`y.z.com`,那么适用于`y.z.com`、`x.y.z.com`、`foo.x.y.z.com`等域名。再比如,Domain 属性是公共域名`github.io`,那么只适用于`github.io`这个域名本身,不适用于它的子域名`wangdoc.github.io`。 + +`Path`属性指定浏览器发出 HTTP 请求时,哪些路径要附带这个 Cookie。只要浏览器发现,`Path`属性是 HTTP 请求路径的开头一部分,就会在头信息里面带上这个 Cookie。比如,`Path`属性是`/`,那么请求`/docs`路径也会包含该 Cookie。当然,前提是 Domain 属性必须符合条件。 ### Secure,HttpOnly From 8ea87244214dcf50d3aec0b60920eaafabfb028d Mon Sep 17 00:00:00 2001 From: ruanyf Date: Thu, 28 Oct 2021 19:08:55 +0800 Subject: [PATCH 03/45] docs(dom/element): fixed #234 --- docs/dom/element.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/docs/dom/element.md b/docs/dom/element.md index b569f31..2b5ea6d 100644 --- a/docs/dom/element.md +++ b/docs/dom/element.md @@ -89,7 +89,7 @@ document.documentElement.lang // "en" **(1)Element.hidden** -`Element.hidden`属性返回一个布尔值,表示当前元素的`hidden`属性,用来控制当前元素是否可见。该属性可读写。 +`Element.hidden`属性返回一个布尔值,表示当前 HTML 元素的`hidden`属性的值。该属性可读写,用来控制当前元素是否可见。 ```javascript var btn = document.getElementById('btn'); @@ -100,9 +100,9 @@ btn.addEventListener('click', function () { }, false); ``` -注意,该属性与 CSS 设置是互相独立的。CSS 对这个元素可见性的设置,`Element.hidden`并不能反映出来。也就是说,这个属性并不能用来判断当前元素的实际可见性。 +注意,该属性与 CSS 设置是互相独立的。CSS 对当前元素可见性的设置,`Element.hidden`并不能反映出来。也就是说,这个属性并不能用来判断当前元素的实际可见性。 -CSS 的设置高于`Element.hidden`。如果 CSS 指定了该元素不可见(`display: none`)或可见(`display: hidden`),那么`Element.hidden`并不能改变该元素实际的可见性。换言之,这个属性只在 CSS 没有明确设定当前元素的可见性时才有效。 +CSS 设置的优先级高于`Element.hidden`。如果 CSS 指定了该元素不可见(`display: none`)或可见(`visibility: visible`),那么`Element.hidden`并不能改变该元素实际的可见性。换言之,这个属性只在 CSS 没有明确设定当前元素的可见性时才有效。 **(2)Element.contentEditable,Element.isContentEditable** From c426ae28ced38a3e56fc18ec3215bfaf266ea1df Mon Sep 17 00:00:00 2001 From: ruanyf Date: Fri, 29 Oct 2021 08:05:50 +0800 Subject: [PATCH 04/45] docs(dom/nodelist): edit HTMLCollection.prototype.namedItem() --- docs/dom/nodelist.md | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/docs/dom/nodelist.md b/docs/dom/nodelist.md index f5c9457..bda3939 100644 --- a/docs/dom/nodelist.md +++ b/docs/dom/nodelist.md @@ -179,7 +179,7 @@ var img0 = c.item(0); ### HTMLCollection.prototype.namedItem() -`namedItem`方法的参数是一个字符串,表示`id`属性或`name`属性的值,返回对应的元素节点。如果没有对应的节点,则返回`null`。 +`namedItem`方法的参数是一个字符串,表示`id`属性或`name`属性的值,返回当前集合中对应的元素节点。如果没有对应的节点,则返回`null`。 ```javascript // HTML 代码如下 @@ -188,3 +188,6 @@ var img0 = c.item(0); var pic = document.getElementById('pic'); document.images.namedItem('pic') === pic // true ``` + +`Collection.namedItem('value')`等同于`Collection['value']`。 + From 074e7f591a70b1110a22a120c9f8bf6a74788001 Mon Sep 17 00:00:00 2001 From: ruanyf Date: Sat, 5 Feb 2022 09:04:13 +0800 Subject: [PATCH 05/45] docs(stdlib/date): fix #237 --- docs/stdlib/date.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/stdlib/date.md b/docs/stdlib/date.md index 4edbaeb..af7ad94 100644 --- a/docs/stdlib/date.md +++ b/docs/stdlib/date.md @@ -361,7 +361,7 @@ d.toLocaleTimeString('zh-CN') // "上午12:00:00" - `weekday`:可能的值为`long`、`short`、`narrow`。 - `day`、`hour`、`minute`、`second`:可能的值为`numeric`、`2-digit`。 - `timeZone`:可能的值为 IANA 的时区数据库。 -- `timeZooneName`:可能的值为`long`、`short`。 +- `timeZoneName`:可能的值为`long`、`short`。 - `hour12`:24小时周期还是12小时周期,可能的值为`true`、`false`。 下面是用法实例。 From f901426d946ba4ced8f3b0ff70bc73d01e27c382 Mon Sep 17 00:00:00 2001 From: Jim Gao Date: Tue, 1 Mar 2022 13:14:29 +0800 Subject: [PATCH 06/45] docs: fix url (#239) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * fix url * fix url * docs(basic/grammar): update url Update 2013-06-22: “Basic JavaScript: an introduction to the language” is an improved longer version of this post * docs(types/number): fix url * docs(types/object): remove extra word * docs(types/function): fix url * docs(operators/bit): update url * docs(features/style): fix url * docs(stdlib/date): update url * docs(oop/prototype): update url * docs(async/promise): fix url * docs(bom/engine): update url --- docs/async/promise.md | 2 +- docs/basic/grammar.md | 2 +- docs/basic/history.md | 6 +++--- docs/bom/engine.md | 2 +- docs/features/style.md | 2 +- docs/oop/prototype.md | 2 +- docs/operators/bit.md | 2 +- docs/stdlib/date.md | 4 ++-- docs/types/function.md | 2 +- docs/types/number.md | 2 +- docs/types/object.md | 2 +- 11 files changed, 14 insertions(+), 14 deletions(-) diff --git a/docs/async/promise.md b/docs/async/promise.md index 68b5c07..cb629d7 100644 --- a/docs/async/promise.md +++ b/docs/async/promise.md @@ -274,7 +274,7 @@ console.log(3); ## 参考链接 -- Sebastian Porto, [Asynchronous JS: Callbacks, Listeners, Control Flow Libs and Promises](http://sporto.github.com/blog/2012/12/09/callbacks-listeners-promises/) +- Sebastian Porto, [Asynchronous JS: Callbacks, Listeners, Control Flow Libs and Promises](https://sporto.github.io/blog/2012/12/09/callbacks-listeners-promises/) - Rhys Brett-Bowen, [Promises/A+ - understanding the spec through implementation](http://modernjavascript.blogspot.com/2013/08/promisesa-understanding-by-doing.html) - Matt Podwysocki, Amanda Silver, [Asynchronous Programming in JavaScript with “Promises”](http://blogs.msdn.com/b/ie/archive/2011/09/11/asynchronous-programming-in-javascript-with-promises.aspx) - Marc Harter, [Promise A+ Implementation](https://gist.github.com//wavded/5692344) diff --git a/docs/basic/grammar.md b/docs/basic/grammar.md index 1611427..b1ebde1 100644 --- a/docs/basic/grammar.md +++ b/docs/basic/grammar.md @@ -727,4 +727,4 @@ top: ## 参考链接 -- Axel Rauschmayer, [A quick overview of JavaScript](http://www.2ality.com/2011/10/javascript-overview.html) +- Axel Rauschmayer, [Basic JavaScript for the impatient programmer](https://2ality.com/2013/06/basic-javascript.html) diff --git a/docs/basic/history.md b/docs/basic/history.md index 0c03d6d..f5c266b 100644 --- a/docs/basic/history.md +++ b/docs/basic/history.md @@ -181,7 +181,7 @@ JavaScript 伴随着互联网的发展一起发展。互联网周边技术的快 ## 参考链接 -- Axel Rauschmayer, [The Past, Present, and Future of JavaScript](http://oreilly.com/javascript/radarreports/past-present-future-javascript.csp) +- Axel Rauschmayer, [The Past, Present, and Future of JavaScript](https://www.oreilly.com/library/view/the-past-present/9781449343545/) - John Dalziel, [The race for speed part 4: The future for JavaScript](http://creativejs.com/2013/06/the-race-for-speed-part-4-the-future-for-javascript/) -- Axel Rauschmayer, [Basic JavaScript for the impatient programmer](http://www.2ality.com/2013/06/basic-javascript.html) -- resin.io, [Happy 18th Birthday JavaScript! A look at an unlikely past and bright future](http://resin.io/happy-18th-birthday-javascript/) +- Axel Rauschmayer, [Basic JavaScript for the impatient programmer](https://www.2ality.com/2013/06/basic-javascript.html) +- balena.io, [Happy 18th Birthday JavaScript! A look at an unlikely past and bright future](https://www.balena.io/blog/happy-18th-birthday-javascript/) diff --git a/docs/bom/engine.md b/docs/bom/engine.md index 86e7f53..8c0761e 100644 --- a/docs/bom/engine.md +++ b/docs/bom/engine.md @@ -436,4 +436,4 @@ JavaScript 是一种解释型语言,也就是说,它不需要编译,由解 - Axel Rauschmayer, [ECMAScript 6 promises (1/2): foundations](http://www.2ality.com/2014/09/es6-promises-foundations.html) - Daniel Imms, [async vs defer attributes](http://www.growingwiththeweb.com/2014/02/async-vs-defer-attributes.html) - Craig Buckler, [Load Non-blocking JavaScript with HTML5 Async and Defer](http://www.sitepoint.com/non-blocking-async-defer/) -- Domenico De Felice, [How browsers work](http://domenicodefelice.blogspot.sg/2015/08/how-browsers-work.html?t=2) +- Domenico De Felice, [How browsers work](https://domenicodefelice.blogspot.com/2015/08/how-browsers-work.html) diff --git a/docs/features/style.md b/docs/features/style.md index 8947aca..0ea77e1 100644 --- a/docs/features/style.md +++ b/docs/features/style.md @@ -486,7 +486,7 @@ function doAction(action) { ## 参考链接 -- Eric Elliott, Programming JavaScript Applications, [Chapter 2. JavaScript Style Guide](http://chimera.labs.oreilly.com/books/1234000000262/ch02.html), O'Reilly, 2013 +- Eric Elliott, Programming JavaScript Applications, [Chapter 2. JavaScript Style Guide](https://www.oreilly.com/library/view/programming-javascript-applications/9781491950289/), O'Reilly, 2014 - Axel Rauschmayer, [A meta style guide for JavaScript](http://www.2ality.com/2013/07/meta-style-guide.html) - Axel Rauschmayer, [Automatic semicolon insertion in JavaScript](http://www.2ality.com/2011/05/semicolon-insertion.html) - Rod Vagg, [JavaScript and Semicolons](http://dailyjs.com/2012/04/19/semicolons/) diff --git a/docs/oop/prototype.md b/docs/oop/prototype.md index 76077e2..d1ae8df 100644 --- a/docs/oop/prototype.md +++ b/docs/oop/prototype.md @@ -637,4 +637,4 @@ var module1 = (function ($, YAHOO) { ## 参考链接 -- [JavaScript Modules: A Beginner’s Guide](https://medium.freecodecamp.com/javascript-modules-a-beginner-s-guide-783f7d7a5fcc), by Preethi Kasireddy +- [JavaScript Modules: A Beginner’s Guide](https://www.freecodecamp.org/news/javascript-modules-a-beginner-s-guide-783f7d7a5fcc), by Preethi Kasireddy diff --git a/docs/operators/bit.md b/docs/operators/bit.md index edbb8b4..3c86e3d 100644 --- a/docs/operators/bit.md +++ b/docs/operators/bit.md @@ -353,6 +353,6 @@ flags = ~flags; ## 参考链接 -- Michal Budzynski, [JavaScript: The less known parts. Bitwise Operators](http://michalbe.blogspot.co.uk/2013/03/javascript-less-known-parts-bitwise.html) +- Michal Budzynski, [JavaScript: The less known parts. Bitwise Operators](https://michalbe.blogspot.com/2013/03/javascript-less-known-parts-bitwise.html) - Axel Rauschmayer, [Basic JavaScript for the impatient programmer](http://www.2ality.com/2013/06/basic-javascript.html) - Mozilla Developer Network, [Bitwise Operators](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/Bitwise_Operators) diff --git a/docs/stdlib/date.md b/docs/stdlib/date.md index af7ad94..2b0326e 100644 --- a/docs/stdlib/date.md +++ b/docs/stdlib/date.md @@ -545,5 +545,5 @@ d // Sun Jan 06 2013 06:00:00 GMT+0800 (CST) ## 参考链接 -- Rakhitha Nimesh,[Getting Started with the Date Object](http://jspro.com/raw-javascript/beginners-guide-to-javascript-date-and-time/) -- Ilya Kantor, [Date/Time functions](http://javascript.info/tutorial/datetime-functions) +- Rakhitha Nimesh,[Getting Started with the Date Object](https://www.sitepoint.com/beginners-guide-to-javascript-date-and-time/) +- Ilya Kantor, [Date/Time functions](https://javascript.info/date) diff --git a/docs/types/function.md b/docs/types/function.md index d8e649e..ef8625f 100644 --- a/docs/types/function.md +++ b/docs/types/function.md @@ -993,7 +993,7 @@ window.eval('...') - Ben Alman, [Immediately-Invoked Function Expression (IIFE)](http://benalman.com/news/2010/11/immediately-invoked-function-expression/) - Mark Daggett, [Functions Explained](http://markdaggett.com/blog/2013/02/15/functions-explained/) -- Juriy Zaytsev, [Named function expressions demystified](http://kangax.github.com/nfe/) +- Juriy Zaytsev, [Named function expressions demystified](http://kangax.github.io/nfe/) - Marco Rogers polotek, [What is the arguments object?](http://docs.nodejitsu.com/articles/javascript-conventions/what-is-the-arguments-object) - Juriy Zaytsev, [Global eval. What are the options?](http://perfectionkills.com/global-eval-what-are-the-options/) - Axel Rauschmayer, [Evaluating JavaScript code via eval() and new Function()](http://www.2ality.com/2014/01/eval.html) diff --git a/docs/types/number.md b/docs/types/number.md index af8954e..64f0592 100644 --- a/docs/types/number.md +++ b/docs/types/number.md @@ -651,4 +651,4 @@ isFinite(-1) // true ## 参考链接 - Dr. Axel Rauschmayer, [How numbers are encoded in JavaScript](http://www.2ality.com/2012/04/number-encoding.html) -- Humphry, [JavaScript 中 Number 的一些表示上/下限](http://blog.segmentfault.com/humphry/1190000000407658) +- Humphry, [JavaScript 中 Number 的一些表示上/下限](https://segmentfault.com/a/1190000000407658) diff --git a/docs/types/object.md b/docs/types/object.md index 9e50984..3ff539c 100644 --- a/docs/types/object.md +++ b/docs/types/object.md @@ -497,5 +497,5 @@ console.log(temp.p1 + temp.p2); - Dr. Axel Rauschmayer,[Object properties in JavaScript](http://www.2ality.com/2012/10/javascript-properties.html) - Lakshan Perera, [Revisiting JavaScript Objects](http://www.laktek.com/2012/12/29/revisiting-javascript-objects/) -- Angus Croll, [The Secret Life of JavaScript Primitives](http://javascriptweblog.wordpress.com/2010/09/27/the-secret-life-of-javascript-primitives/)i +- Angus Croll, [The Secret Life of JavaScript Primitives](http://javascriptweblog.wordpress.com/2010/09/27/the-secret-life-of-javascript-primitives/) - Dr. Axel Rauschmayer, [JavaScript’s with statement and why it’s deprecated](http://www.2ality.com/2011/06/with-statement.html) From bf18144c97bae1662f72cc02ecbbf7d75093a076 Mon Sep 17 00:00:00 2001 From: ruanyf Date: Tue, 1 Mar 2022 13:41:56 +0800 Subject: [PATCH 07/45] docs(types/function): fix #239 broken reference link --- docs/types/function.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/types/function.md b/docs/types/function.md index ef8625f..76dcbfb 100644 --- a/docs/types/function.md +++ b/docs/types/function.md @@ -992,7 +992,7 @@ window.eval('...') ## 参考链接 - Ben Alman, [Immediately-Invoked Function Expression (IIFE)](http://benalman.com/news/2010/11/immediately-invoked-function-expression/) -- Mark Daggett, [Functions Explained](http://markdaggett.com/blog/2013/02/15/functions-explained/) +- Mark Daggett, [Functions Explained](https://web.archive.org/web/20160911170816/http://markdaggett.com/blog/2013/02/15/functions-explained/) - Juriy Zaytsev, [Named function expressions demystified](http://kangax.github.io/nfe/) - Marco Rogers polotek, [What is the arguments object?](http://docs.nodejitsu.com/articles/javascript-conventions/what-is-the-arguments-object) - Juriy Zaytsev, [Global eval. What are the options?](http://perfectionkills.com/global-eval-what-are-the-options/) From b5ccb913171f73f18b8743701d37a6e1e53df0d1 Mon Sep 17 00:00:00 2001 From: hehe1111 <2908749709@qq.com> Date: Tue, 5 Apr 2022 20:50:45 +0800 Subject: [PATCH 08/45] =?UTF-8?q?=E8=B7=9F=20160=20=E8=A1=8C=E7=9A=84=20Co?= =?UTF-8?q?ntent-Type=20=E9=87=8D=E5=A4=8D=E4=BA=86=20(#241)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- docs/bom/cors.md | 1 - 1 file changed, 1 deletion(-) diff --git a/docs/bom/cors.md b/docs/bom/cors.md index 368ea0c..23dfac9 100644 --- a/docs/bom/cors.md +++ b/docs/bom/cors.md @@ -162,7 +162,6 @@ Content-Encoding: gzip Content-Length: 0 Keep-Alive: timeout=2, max=100 Connection: Keep-Alive -Content-Type: text/plain ``` 上面的 HTTP 回应中,关键的是`Access-Control-Allow-Origin`字段,表示`http://api.bob.com`可以请求数据。该字段也可以设为星号,表示同意任意跨源请求。 From c0737828d443c2fb939054417c0a22a7505f0c75 Mon Sep 17 00:00:00 2001 From: ruanyf Date: Thu, 7 Apr 2022 13:47:00 +0800 Subject: [PATCH 09/45] docs(elements/input): edit valueAsNumber --- docs/elements/input.md | 13 +- package-lock.json | 1523 ---------------------------------------- 2 files changed, 12 insertions(+), 1524 deletions(-) delete mode 100644 package-lock.json diff --git a/docs/elements/input.md b/docs/elements/input.md index 9a04e0e..fce544a 100644 --- a/docs/elements/input.md +++ b/docs/elements/input.md @@ -75,7 +75,18 @@ - `labels`:返回一个`NodeList`实例,代表绑定当前``节点的`