clean up prelude (#4416)

* clear away prelude on dioxus

* clippy

* wip - drop prelude from dioxus-html

* docs clippy

* wip

* more fixe

* delete all preludes

* doc...

* better export

* merge some imports

* fewer global imports

* global incremental renderer

* fix cargo doc
This commit is contained in:
Jonathan Kelley authored and GitHub committed 2025-07-16 16:04:13 -07:00
1 parent 54d465a7b5
commit 4f1d039bad
140 files changed
+374 -477

No files matched your search

+3 -3
View File
@@ -1,6 +1,6 @@
#![allow(missing_docs)]
use crate::{use_callback, use_hook_did_run, use_signal};
use dioxus_core::prelude::*;
use dioxus_core::{use_hook, Callback, Task};
use dioxus_signals::*;
use std::future::Future;
use std::ops::Deref;
@@ -8,7 +8,7 @@ use std::ops::Deref;
/// A hook that allows you to spawn a future the first time you render a component.
///
///
/// This future will **not** run on the server. To run a future on the server, you should use [`spawn_isomorphic`] directly.
/// This future will **not** run on the server. To run a future on the server, you should use [`dioxus_core::spawn_isomorphic`] directly.
///
///
/// `use_future` **won't return a value**. If you want to return a value from a future, use [`crate::use_resource()`] instead.
@@ -50,7 +50,7 @@ where
let callback = use_callback(move |_| {
let fut = future();
spawn(async move {
dioxus_core::spawn(async move {
state.set(UseFutureState::Pending);
fut.await;
state.set(UseFutureState::Ready);