feat: refactor out the hooks implementation
This commit is contained in:
1 parent
eb82051000
commit
1cc1679a6b
8 files changed
+163
-37
No files matched your search
@@ -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!()
|
||||
};
|
||||
Reference in new issue
Block a user