8000
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 2828fd1 commit c526167Copy full SHA for c526167
idl/zh-cn/url.idl
@@ -23,9 +23,9 @@ Url 类的常用属性和方法如下:
23
下面是一个 url 模块的示例:
24
25
```JavaScript
26
-const { Url } = require('url');
+const { URL } = require('url');
27
28
-const url = new Url('http://www.baidu.com/s?ie=UTF-8&wd=fibjs#hash');
+const url = new URL('http://www.baidu.com/s?ie=UTF-8&wd=fibjs#hash');
29
console.log(url.protocol); // 'http:'
30
console.log(url.host); // 'www.baidu.com'
31
console.log(url.path); // '/s?ie=UTF-8&wd=fibjs'
0 commit comments