ec changed the topic of #elliottcable to: a π―ππ ππ π―πππππππππ π―ππππππ slash sΝΜuΝΝpΝΝeΜΜΊrΜΌΜ¦iΜΌΜoΜΜ¬rΜΜ cΜΝα»₯Μ§ΝαΈ·Μ‘ΝΕ£ΝΜ || #ELLIOTTCABLE is not about ELLIOTTCABLE
Rurik has quit [Quit: Rurik]
Sgeo_ has joined #elliottcable
Sgeo__ has quit [Ping timeout: 240 seconds]
_whitelogger has joined #elliottcable
Rurik has joined #elliottcable
_whitelogger has joined #elliottcable
Rurik has quit [Quit: Rurik]
Rurik has joined #elliottcable
Rurik has quit [Quit: Rurik]
<ec>
anybody use Linux on the desktop and got a second to try something for me? I've spent all goddamn day banging my head against VMware and Linux Mint and apt-get and open-vm-tools and all I goddamn want is to run a few git commands
<ec>
someone be lovely and try this for me on their machine? because my git checkout is failing on Travis, but only on the Linux workers, and I can't fucking figure out why
<jfhbrook>
ec: it's react hooks :) and yeah it's super whacky but I kinda like it
<jfhbrook>
ec: the way they work is that useState has access to a closure where it tracks the state, and it depends on controlling the lifecycle of the component to know which component is active for any given hook (basically)
<jfhbrook>
ec: but it's a replacement for the this.setState pattern, end of day
<jfhbrook>
oh, but I can give your linux thing a shot later, I'm going home very soon
<ec>
I don't know the this.setState pattern; I don't use React
<ec>
jfhbrook: that'd be very nice, yes
<ec>
having a linux nightmare today
<jfhbrook>
ec: so the way react components work is *waves hands* react holds onto a tree of components and re-instantiates them when it decides it needs to re-render - and rendering in the first place is due to immutable "props" and highly mutable "state", but the way it manages state using the OG class API is that the React.Component class has a method called setState that you use instead of manually modifying self.state
<jfhbrook>
so when you call self.setState() it triggers react to recalculate its virtual DOMitude or whatever
<jfhbrook>
hooks are an alternate API that let you return a function rather than a Component with a render() method
<jfhbrook>
but it's all the same shit, just a more clever/weird API
<jfhbrook>
by "re-instantiate" for Components I actually meant re-render - for hooks it has to call the "component function" instead
<ec>
lol k
<ec>
react is all greek to me but whadduh I know
<jfhbrook>
yeah, this is all new to me too
<jfhbrook>
after years of "eventually" I decided that I wanted to make an App
<ec>
people are all on about props at conferences and I just tune out until they get back to the good stuff :P
<jfhbrook>
and now I have a little react app that I'm enjoying
<jfhbrook>
react is decent
<jfhbrook>
the community is kinda dumb and there is a *lot* of really dumb shit built around it, like react-router and redux and I mean realistically you need webpack and babel now too
<jfhbrook>
total circus to get up and running
<jfhbrook>
but once you have it going it's alright