wip: remove hooks warnigns
This commit is contained in:
1 parent
c1f8424693
commit
d78815103d
3 files changed
+11
-14
No files matched your search
+7
-6
@@ -20,8 +20,7 @@ dioxus-web = { path = "./packages/web", version = "^0.0.2", optional = true }
|
|||||||
dioxus-desktop = { path = "./packages/desktop", optional = true }
|
dioxus-desktop = { path = "./packages/desktop", optional = true }
|
||||||
dioxus-ssr = { path = "./packages/ssr", optional = true }
|
dioxus-ssr = { path = "./packages/ssr", optional = true }
|
||||||
|
|
||||||
dioxus-router = { path = "./packages/router", optional = true }
|
# dioxus-router = { path = "./packages/router", optional = true }
|
||||||
|
|
||||||
# dioxus-mobile = { path = "./packages/mobile", optional = true }
|
# dioxus-mobile = { path = "./packages/mobile", optional = true }
|
||||||
# dioxus-liveview = { path = "./packages/liveview", optional = true }
|
# dioxus-liveview = { path = "./packages/liveview", optional = true }
|
||||||
|
|
||||||
@@ -31,12 +30,14 @@ default = ["macro", "hooks", "html"]
|
|||||||
macro = ["dioxus-core-macro"]
|
macro = ["dioxus-core-macro"]
|
||||||
hooks = ["dioxus-hooks"]
|
hooks = ["dioxus-hooks"]
|
||||||
html = ["dioxus-html"]
|
html = ["dioxus-html"]
|
||||||
router = ["dioxus-router"]
|
|
||||||
ssr = ["dioxus-ssr"]
|
ssr = ["dioxus-ssr"]
|
||||||
web = ["dioxus-web", "dioxus-router/web"]
|
web = ["dioxus-web"]
|
||||||
desktop = ["dioxus-desktop", "dioxus-router/desktop"]
|
desktop = ["dioxus-desktop"]
|
||||||
|
|
||||||
|
|
||||||
|
# router = ["dioxus-router"]
|
||||||
|
# "dioxus-router/web"
|
||||||
|
# "dioxus-router/desktop"
|
||||||
|
# desktop = ["dioxus-desktop", "dioxus-router/desktop"]
|
||||||
# mobile = ["dioxus-mobile"]
|
# mobile = ["dioxus-mobile"]
|
||||||
# liveview = ["dioxus-liveview"]
|
# liveview = ["dioxus-liveview"]
|
||||||
|
|
||||||
|
|||||||
@@ -24,10 +24,6 @@ impl<T> UseStateOwned<T> {
|
|||||||
pub fn modify(&self) -> RefMut<T> {
|
pub fn modify(&self) -> RefMut<T> {
|
||||||
RefMut::map(self.wip.borrow_mut(), |x| x.as_mut().unwrap())
|
RefMut::map(self.wip.borrow_mut(), |x| x.as_mut().unwrap())
|
||||||
}
|
}
|
||||||
|
|
||||||
pub fn with(&self, f: impl FnOnce(&mut T)) {
|
|
||||||
//
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
use std::ops::{Add, AddAssign, Div, DivAssign, Mul, MulAssign, Sub, SubAssign};
|
use std::ops::{Add, AddAssign, Div, DivAssign, Mul, MulAssign, Sub, SubAssign};
|
||||||
|
|||||||
@@ -20,9 +20,9 @@ pub fn use_suspense<R: 'static, F: Future<Output = R> + 'static>(
|
|||||||
|
|
||||||
let task = cx.push_future(new_fut);
|
let task = cx.push_future(new_fut);
|
||||||
SuspenseInner {
|
SuspenseInner {
|
||||||
task,
|
_task: task,
|
||||||
value: None,
|
value: None,
|
||||||
wip_value,
|
_wip_value: wip_value,
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
@@ -35,7 +35,7 @@ pub fn use_suspense<R: 'static, F: Future<Output = R> + 'static>(
|
|||||||
}
|
}
|
||||||
|
|
||||||
struct SuspenseInner<R> {
|
struct SuspenseInner<R> {
|
||||||
task: TaskId,
|
_task: TaskId,
|
||||||
wip_value: Rc<Cell<Option<R>>>,
|
_wip_value: Rc<Cell<Option<R>>>,
|
||||||
value: Option<R>,
|
value: Option<R>,
|
||||||
}
|
}
|
||||||
Reference in new issue
Block a user