mirror of
https://github.com/zed-industries/zed.git
synced 2024-12-26 08:42:21 +03:00
Update crates/ui/docs/hello-world.md TODO with explanation of SharedString usage (#10664)
Filled out a comment where there was a TODO to explain SharedString usage. Release Notes: - N/A
This commit is contained in:
parent
c76bacb974
commit
535bcfad10
@ -40,7 +40,7 @@ impl<V: 'static> TodoList<V> {
|
||||
|
||||
All of this is relatively straightforward.
|
||||
|
||||
We use [gpui::SharedString] in components instead of [std::string::String]. This allows us to [TODO: someone who actually knows please explain why we use SharedString].
|
||||
We use [gpui::SharedString] in components instead of [std::string::String]. This allows us to efficiently handle shared string data across multiple components and threads without the performance overhead of copying strings.
|
||||
|
||||
When we want to pass an action we pass a `ClickHandler`. Whenever we want to add an action, the struct it belongs to needs to be generic over the view type `V`.
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user