Misc rename

This commit is contained in:
JMS55 2023-12-05 22:53:18 -08:00
parent da22fe5acf
commit 1372c44b2a
2 changed files with 2 additions and 2 deletions

View file

@ -68,7 +68,7 @@ pub fn use_world<'a>(cx: &'a ScopeState) -> &'a World {
.world_read_only .world_read_only
} }
pub fn use_res<'a, T: Resource>(cx: &'a ScopeState) -> &'a T { pub fn use_resource<'a, T: Resource>(cx: &'a ScopeState) -> &'a T {
cx.consume_context::<EcsContext>() cx.consume_context::<EcsContext>()
.expect("Must be used from a dioxus component within a DioxusUiRoot bevy component") .expect("Must be used from a dioxus component within a DioxusUiRoot bevy component")
.world_read_only .world_read_only

View file

@ -6,7 +6,7 @@ use bevy::{
ecs::component::Component, ecs::component::Component,
}; };
pub use self::implementation::{use_commands, use_res, use_world}; pub use self::implementation::{use_commands, use_resource, use_world};
pub use dioxus_core::{Element, Scope}; pub use dioxus_core::{Element, Scope};
pub struct DioxusUiPlugin; pub struct DioxusUiPlugin;