Methods
-
(static) loadJSON(file, postopt, getopt) → {Promise}
-
Parameters:
Name Type Attributes Description file
String post
String | Object <optional>
get
String | Object <optional>
- Source:
Returns:
- Type
- Promise
-
(static) loadJSONP(file, getopt) → {Promise}
-
Parameters:
Name Type Attributes Description file
String get
String | Object <optional>
- Source:
Returns:
- Type
- Promise
Example
Request.loadJSONP("http://example.com/?cb=?"); Request.loadJSONP("http://example.com/?cb=%3F"); Request.loadJSONP("http://example.com/", { cb: "?" }); Request.loadJSONP("http://example.com/"); // automatically adds `?callback=?`
-
(static) loadJSONSync(file, postopt, getopt) → {*}
-
Parameters:
Name Type Attributes Description file
String post
String | Object <optional>
get
String | Object <optional>
- Source:
Returns:
- Type
- *
-
(static) loadScript(file, getopt) → {Promise}
-
Parameters:
Name Type Attributes Description file
String get
String | Object <optional>
- Source:
Returns:
- Type
- Promise
-
(static) loadText(file, postopt, getopt) → {Promise}
-
Parameters:
Name Type Attributes Description file
String post
String | Object <optional>
get
String | Object <optional>
- Source:
Returns:
- Type
- Promise
-
(static) loadTextSync(file, postopt, getopt) → {String}
-
Parameters:
Name Type Attributes Description file
String post
String | Object <optional>
get
String | Object <optional>
- Source:
Returns:
- Type
- String