feat: refactor out the hooks implementation

This commit is contained in:
Jonathan Kelley committed 2021-07-09 01:26:15 -04:00
1 parent eb82051000
commit 1cc1679a6b
8 files changed
+163 -37

No files matched your search

+21
View File
@@ -0,0 +1,21 @@
use std::pin::Pin;
use dioxus_core::prelude::*;
use futures::Future;
fn main() {}
const App: FC<()> = |cx| {
let mut fut = cx.use_hook(
|| {
//
Box::pin(async { loop {} }) as Pin<Box<dyn Future<Output = ()>>>
},
|f| f,
|_| {},
);
cx.submit_task(fut);
todo!()
};