mirror of
https://github.com/fluencelabs/wasm-bindgen
synced 2025-06-19 07:51:26 +00:00
Fix fetch example ... again?
This commit is contained in:
@ -46,7 +46,7 @@ pub fn run() -> Promise {
|
||||
request_options.method("GET");
|
||||
request_options.mode(RequestMode::Cors);
|
||||
|
||||
let req = Request::new_with_str_and_request_init("https://api.github.com/repos/rustwasm/wasm-bindgen/branches/master", &request_options).unwrap();
|
||||
let req = Request::new_with_str_and_init("https://api.github.com/repos/rustwasm/wasm-bindgen/branches/master", &request_options).unwrap();
|
||||
|
||||
// the RequestInit struct will eventually support setting headers, but that's missing right now
|
||||
req.headers().set("Accept", "application/vnd.github.v3+json").unwrap();
|
||||
|
Reference in New Issue
Block a user