Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
lopatin
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
47 ms
·
571.
▲
by
lopatin
11y ago
I recently adopted the "you shouldn't have to think about your toolset" and "use boring technology" mindsets. I learned React but I stopped following all other wonderful work being done by the community. It was just
572.
▲
by
lopatin
11y ago
Thanks for the link. As someone who's never heard of Dweck, I learned a lot from Aaron's point of view on the topic. Also Gates is totally right when he says that this isn't black and white. I'm growth mindset about some
573.
▲
by
lopatin
11y ago
I'm sure it's a great service. I found it a little funny that this is a CDN that is "not [yet] recommended for production use".
574.
▲
by
lopatin
11y ago
Looks like it's actually Go based on one of the JSON responses I found in the web page: { ok: false, error: "strconv.ParseInt: parsing "NaN": invalid syntax" }
575.
▲
by
lopatin
11y ago
Yeah I don't get it. I guess the only other thing that stood out for me was that the message is "Sorry something went wrong" except that 404 is a user error. "Sorry" is usually used for 500s.
576.
▲
by
lopatin
11y ago
I actually think that Option 1, where Ann has her salary lowered after moving out of the valley is the most reasonable way to handle remote compensation. In other words, as an employee you get compensated by the quality of life that you can
577.
▲
by
lopatin
11y ago
I think the beginning of this article is spot on. A declarative UI library for the web needs to have something like virtual DOM so that the actual DOM is strategically updated when a higher level component updates. No DOM state like input f
578.
▲
by
lopatin
11y ago
Does anyone have experience with Riak vs Mnesia as a backend for the various Erlang XMPP servers?
579.
▲
by
lopatin
11y ago
I didn't follow the last sentence. Does every pull request get reviewed by a human before merge? At what stage does the human rejection happen? The smart deep learning bot can determine if a branch is "clean", but it surely c
580.
▲
by
lopatin
11y ago
I don't blame you for blocking ads because a lot of them are really out of hand (intrusive and deceptive) but I believe your reasoning for having no obligation to view ads is faulty. If everything is fair and square, I believe that you
581.
▲
by
lopatin
11y ago
The lines don't seem to be over 80 chars long. It's code golf so it's still going to be hard to read but the 80 char lines are acceptable in most code bases.
582.
▲
by
lopatin
11y ago
This is great. One big reason that I'm so excited to see more tools like this is that they have the potential to make unit testing less annoying. Build your component and take snapshots of it in different states with different props. C
583.
▲
by
lopatin
11y ago
This is pretty cool. Maybe can be useful as a safe alternative to eval()?
584.
▲
by
lopatin
11y ago
Thanks! Glad to hear it was easy to follow and didn't ramble. Our backbone model cache is a simple module that you request backbone model instances from by a unique key. You also pass initialization options in case it doesn't exis
585.
▲
by
lopatin
11y ago
Oh this is definitely a personal preference thing, but our convention is this: private instance methods start with an underscore, public instance methods have no underscore. Public ones have no syntactic difference from the core life cycle
586.
▲
by
lopatin
11y ago
It looks like you're bucketing the ideas in the post into one of two categories. Either 1. Too obvious to write about or 2. Not a best practice because new ideas are always being introduced. Regarding the first, those topics weren'
587.
▲
by
lopatin
11y ago
That's pretty much it! Although the ideas presented here do make sense ( https://speakerdeck.com/vjeux/react-css-in-js ) we haven't gotten there yet. Our css namespacing scheme solves the "global namespace
588.
▲
by
lopatin
11y ago
Nice, we're actually posting a tutorial in a week or two about how we use d3 + react. I'll try to summarize though. In the case that a library modifies the DOM, we try to keep React out of it's way. React works best when it h
589.
▲
by
lopatin
11y ago
The latter. Most of our components have an associated scss file. I didn't consider those to be global because we namespace all css rules in the style files under a class name of the same name as the component. But that's a great p
590.
▲
by
lopatin
11y ago
One reason for the explicit method may be that React does an internal optimization where it batches state updates together. Two calls to setState can result in just one render. https://groups.google.com/forum/#!msg/
591.
▲
by
lopatin
11y ago
Author here, happy to answer any questions or discuss further!
592.
▲
React JS Best Practices
(blog.siftscience.com)
252 points
by
lopatin
11y ago
|
89 comments
593.
▲
Under the hood: Facebook’s cold storage system
(code.facebook.com)
7 points
by
lopatin
11y ago
|
0 comments
594.
▲
Best practices for building large React applications
(blog.siftscience.com)
14 points
by
lopatin
11y ago
|
0 comments
595.
▲
by
lopatin
12y ago
So brilliant, fun, and frustrating. Everyone seems to be Russian. Probably because I'm playing at 2:30 AM.
596.
▲
by
lopatin
12y ago
Great article. One thing I would like to mention is that using component state (this.setState) is okay ! Central stores, and the flux architecture, are very helpful but if your state shouldn't persist after an unmount, there's no
597.
▲
by
lopatin
12y ago
It would take something truly novel to make me consider anything on top of the simple and powerful setup which is react + a custom flux. I don't see much here except some glue that reduces flux boilerplate for actions. It also seems to
598.
▲
by
lopatin
12y ago
1. Stop using frameworks 2. Build project from scratch with well structured JS. 3. Build another project, but first extract the generalizable bits from the first project into a module that solves common problems. 4. Open source this module
599.
▲
by
lopatin
12y ago
Outgrowing Meteor is a valid concern. It's intertwined with your backend and db, so it's definitely a lot of work to migrate off of. I just want to make the distinction between that and JS frameworks that don't try to own you
600.
▲
by
lopatin
12y ago
As a JavaScript programmer, I think I disagree with the author's generalization about languages :)
More ›