Bloomca / veles

UI library with main focus on performance
https://bloomca.github.io/veles/
MIT License
48 stars 0 forks source link

Add <state$.Value />` component #74

Open Bloomca opened 1 month ago

Bloomca commented 1 month ago

Description

Similar to lucy-state, I think a component is a preferred way to interact with rendering the value, as opposed to useRenderValue():

  1. I think the naming is better
  2. semantically, a component is better in the markup compared to a direct function
  3. no difference when we have a selector, it is just a passed property

I don't think the overhead will be any sort of important. In theory, we can add a separate treatment for these components, basically inlining them and treating them similar to if we called useRenderValue() directly.