feat: move over to push based mechanism

This commit is contained in:
Jonathan Kelley committed 2021-07-14 17:39:26 -04:00
1 parent e7238762ae
commit 80e6c25698
7 files changed
+96 -70

No files matched your search

+2 -3
View File
@@ -36,7 +36,7 @@ static App: FC<()> = |cx| {
let state = use_state(cx, || 0);
let set_val = state.setter();
let g = cx.use_task(|| async move {
let (tas, g) = cx.use_task(|| async move {
let mut tick: i32 = 0;
log::debug!("yeet!");
// loop {
@@ -47,10 +47,9 @@ static App: FC<()> = |cx| {
// break;
// }
// }
// String::from("Huzza!")
set_val(10);
surf::get(ENDPOINT).recv_json::<DogApi>().await
// String::from("Huzza!")
});
let dog_node = match g.as_ref().and_then(|f| f.as_ref().ok()) {