3 ms·
As a Vue developer I appreciate this post, explaining how data/template proximity of React can be advantageous. If you like data/template separation Vue might b
by gdbate 6y ago
As a Vue developer I appreciate this post, explaining how data/template proximity of React can be advantageous. If you like data/template separation Vue might be worth a shot.
Vue 3 is introducing a detached renderer, and given it's amazing component boundaries and decision caching it will give React a good run for the money on things like native output.
Vue 3 also introduces the composition API utilizing other features mentioned.
To each is own!
- WorldMaker 6y agoPardon the derailment, but "To each is own" is a fascinating mondegreen [1] I've been seeing surprisingly often lately. The classic phrase was the strangely gendered "to each his own [choice]" and the "proper" phrase is probably "to each their own [choice]". "To each is own" implies something else, but I'm not entirely sure what. "To each is own[er] [of choices]" perhaps? I've seen it like two or three times in recent weeks and find it fascinating. (Sorry, not trying single you out, or derail the conversation too much, but armchair linguistics is a hobby of many on HN and somewhat curious if others have spotted it.) [1] https://en.wikipedia.org/wiki/Mondegreen https://en.wikipedia.org/wiki/Mondegreen
- gdbate 6y agohaha interesting, I think I was trying to emphasis personal preference, some of what picking a framework comes down to.
- eindiran 6y agoIn my idiolect, changing the gender of pronouns inside of idioms is highly marked, even though I use singular "they" as the epicene pronoun. > The classic phrase was ... strangely gendered I don't think it was "strangely" gendered; despite recent growth in the corpus frequency of singular "they", many formal manuals of style still prohibit its usage, preferring "one" as the epicene pronoun. Singular "they" has existed for about as long as Modern English, but generic "he" was significantly more common throughout the 20th century. Given how long idioms take to change, generally speaking, I think it should be unsurprising that this usage of generic "he" remains common. The classic paper on this is "Androcentrism in prescriptive grammar", from 1974, which presents the argument that singular "they" was more common before the prescriptive grammar movement in English, which greater increased how common generic "he" was[0]. [0] https://www.cambridge.org/core/journals/language-in-society/article/abs/androcentrism-in-prescriptive-grammar-singular-they-sexindefinite-he-and-he-or-she1/5F82DDFEC41B3D2BC5E55C29B74310D1 https://www.cambridge.org/core/journals/language-in-society/...
- WorldMaker 6y ago"Strangely" was my simplistic way of very briefly glossing over that history that those "prescriptive grammar" changes was a I feel strange period in the language where Classical Latin studies influenced a redirect of the language's course that shifted a lot of idioms from say their Shakespearean Middle English states for some weird idea that being more like Classical Latin was a good thing for English.
- cercatrova 6y agoProbably a typo on "to each his own"
- SebastianKra 6y agoI wouldn't say that data/template proximity is required or desirable in React. Yes, you _can_ do fetching and rendering in a single function, but that doesn't mean you should. I will even go a step further and say that, in React, there is no data-part. React is nothing but a really powerful templating system. (EDIT: It's actually more nuanced, but this is how I approach it.) The data-layer is usually handled by another library like Redux, Apollo Client or React-Query/useSWR.
- gdbate 6y agothanks for the clarity
- eyelidlessness 6y agoI think probably my proximity point is less clear than it could be. The “proximity” I find appealing is that a component is either a function of data (“props”) returning the rendered structure, or an encapsulation of props and state returning the same... and in those cases (especially with static type checking) makes it easy to understand and navigate data flow, in a way that a template separate from its data types usually isn’t. Of course it’s good to separate the business logic from the rendering, but that still produces a more clear understanding of the data flow.