doc: update url doc to account for escaping
Fixes: https://github.com/nodejs/node/issues/2113 Ref: 17a379ec39a34408477ac6a43751c1b9b2e952a4 PR-URL: https://github.com/nodejs/node/pull/2605 Reviewed-By: jasnell - James M Snell <jasnell@gmail.com> Reviewed-By: cjihrig - Colin Ihrig <cjihrig@gmail.com> Reviewed-By: mscdex - Brian White <mscdex@mscdex.net>
This commit is contained in:
parent
aa0f8bf455
commit
65844affe9
@ -5,6 +5,8 @@
|
|||||||
This module has utilities for URL resolution and parsing.
|
This module has utilities for URL resolution and parsing.
|
||||||
Call `require('url')` to use it.
|
Call `require('url')` to use it.
|
||||||
|
|
||||||
|
## URL Parsing
|
||||||
|
|
||||||
Parsed URL objects have some or all of the following fields, depending on
|
Parsed URL objects have some or all of the following fields, depending on
|
||||||
whether or not they exist in the URL string. Any parts that are not in the URL
|
whether or not they exist in the URL string. Any parts that are not in the URL
|
||||||
string will not be in the parsed object. Examples are shown for the URL
|
string will not be in the parsed object. Examples are shown for the URL
|
||||||
@ -64,6 +66,15 @@ string will not be in the parsed object. Examples are shown for the URL
|
|||||||
|
|
||||||
Example: `'#hash'`
|
Example: `'#hash'`
|
||||||
|
|
||||||
|
### Escaped Characters
|
||||||
|
|
||||||
|
Spaces (`' '`) and the following characters will be automatically escaped in the
|
||||||
|
properties of URL objects:
|
||||||
|
|
||||||
|
< > " ` \r \n \t { } | \ ^ '
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
The following methods are provided by the URL module:
|
The following methods are provided by the URL module:
|
||||||
|
|
||||||
## url.parse(urlStr[, parseQueryString][, slashesDenoteHost])
|
## url.parse(urlStr[, parseQueryString][, slashesDenoteHost])
|
||||||
|
Loading…
x
Reference in New Issue
Block a user