You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This module has built-in support for parsing [JSON](#requestJson), [XML](#requestXml), [CSV](#requestCsv) and [TSV](#requestTsv). You can parse additional formats by using [request](#request) or [requestText](#requestText) directly.
29
+
This module has built-in support for parsing [JSON](#json), [XML](#xml), [CSV](#csv) and [TSV](#tsv). You can parse additional formats by using [request](#request) or [text](#text) directly.
30
30
31
31
## Installing
32
32
@@ -35,8 +35,8 @@ If you use NPM, `npm install d3-request`. Otherwise, download the [latest releas
Sets the response value function to the specified function and returns this request instance. The response value function is used to map the response XMLHttpRequest object to a useful data value. See the convenience methods [requestJson](#requestJson) and [requestText](#requestText) for examples.
91
+
Sets the response value function to the specified function and returns this request instance. The response value function is used to map the response XMLHttpRequest object to a useful data value. See the convenience methods [json](#json) and [text](#text) for examples.
@@ -136,7 +136,7 @@ The type must be one of the following:
136
136
137
137
To register multiple listeners for the same *type*, the type may be followed by an optional name, such as `"load.foo"` and `"load.bar"`. See [d3-dispatch](https://github.com/d3/d3-dispatch) for details.
Creates a request for the [CSV](https://github.com/d3/d3-dsv#csv) file at the specified *url* with the default mime type `"text/csv"`. An optional *row* conversion function may be specified to map and filter row objects to a more-specific representation; see [*dsv*.parse](https://github.com/d3/d3-dsv#dsv_parse) for details. For example:
142
142
@@ -154,13 +154,13 @@ function row(d) {
154
154
The *row* conversion function can be changed by calling *request*.row on the returned instance. For example, this:
Creates a request for the HTML file at the specified *url* with the default mime type "text/html". The HTML file is returned as a [document fragment](https://developer.mozilla.org/en-US/docs/DOM/range.createContextualFragment).
Creates a request for the [TSV](https://github.com/d3/d3-dsv#tsv) file at the specified *url* with the default mime type `"text/tab-separated-values"`. An optional *row* conversion function may be specified to map and filter row objects to a more-specific representation; see [*dsv*.parse](https://github.com/d3/d3-dsv#dsv_parse) for details. For example:
219
219
@@ -231,13 +231,13 @@ function row(d) {
231
231
The *row* conversion function can be changed by calling *request*.row on the returned instance. For example, this:
0 commit comments