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.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I want to fetch data using GET request:
curl http://localhost:5000/v2/_catalog {"repositories":["centos","golang"]}
the struct:
#[derive(Deserialize, Debug, Clone)] pub struct RegistryCatalog { pub repositories: Vec<String>, }
GET request when first render:
fn rendered(&mut self, first_render: bool) { if first_render { ConsoleService::info("view app"); let request = Request::get("http://localhost:5000/v2/_catalog") .body(Nothing) .expect("could not build request."); let callback = self.link.callback( |response: Response<Json<Result<RegistryCatalog, anyhow::Error>>>| { let Json(data) = response.into_body(); ConsoleService::info(&format!("info {:?}", data)); Msg::GetRegistryCatelog(data) }, ); let task = FetchService::fetch(request, callback).expect("failed to start request"); } }
But I got AbortError:
The text was updated successfully, but these errors were encountered:
request header:
Request URL: http://localhost:5000/v2/_catalog Referrer Policy: strict-origin-when-cross-origin Accept: */* Accept-Encoding: gzip, deflate, br Accept-Language: zh-CN,zh;q=0.9,en;q=0.8 Cache-Control: no-cache Connection: keep-alive Host: localhost:5000 Origin: http://127.0.0.1:8080 Pragma: no-cache Referer: http://127.0.0.1:8080/ sec-ch-ua: "Chromium";v="92", " Not A;Brand";v="99", "Google Chrome";v="92" sec-ch-ua-mobile: ?0 Sec-Fetch-Dest: empty Sec-Fetch-Mode: cors Sec-Fetch-Site: cross-site User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/92.0.4515.107 Safari/537.36
Sorry, something went wrong.
Please see #1438
It's worked~
No branches or pull requests
Uh oh!
There was an error while loading. Please reload this page.
I want to fetch data using GET request:
the struct:
GET request when first render:
But I got AbortError:

The text was updated successfully, but these errors were encountered: