Reduce allocations (#30693)
Removes a unnecessary string conversion and some clones Release Notes: - N/A
This commit is contained in:
@@ -20,7 +20,7 @@ impl Modal {
|
||||
pub fn new(id: impl Into<SharedString>, scroll_handle: Option<ScrollHandle>) -> Self {
|
||||
let id = id.into();
|
||||
|
||||
let container_id = ElementId::Name(format!("{}_container", id.clone()).into());
|
||||
let container_id = ElementId::Name(format!("{}_container", id).into());
|
||||
Self {
|
||||
id: ElementId::Name(id),
|
||||
header: ModalHeader::new(),
|
||||
|
||||
Reference in New Issue
Block a user