Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
exogen
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
13 ms
·
91.
▲
by
exogen
6y ago
The package isn't wrong, you're just confused about duck typing.
92.
▲
by
exogen
6y ago
Their code would have been wrong even in strongly typed languages because it considered 0 to be a negative number. What language prevents you from making that mistake?
93.
▲
by
exogen
6y ago
Know what happens every time people like you say this here on HN? They post the one-liner they would have manually implemented in their code base and it's wrong . The one that comes to mind is the "is-negative-number" packag
94.
▲
by
exogen
6y ago
I don't understand the point of transforming things to class instances, though. All of TypeScript's strengths are available without the need for things to be an actual `instanceof` something, right? Can you elaborate? FWIW, I'
95.
▲
by
exogen
7y ago
The subreddit dedicated to this song maintains a spreadsheet of possible leads and sound-alikes. Personally, the first thing that came to mind when I heard the vocals was Type O Negative. Sounds a lot like Peter Steele, but I'm sure a
96.
▲
by
exogen
7y ago
> a large portion of the frame time in that demo is spent in browser code, recalculating styles and redrawing This was my point actually, not that React adds no overhead which of course it does. Updating a property on a bunch of DOM node
97.
▲
by
exogen
7y ago
I think you missed what the conversation was about. > You should easily be able to update tens, if not hundreds of thousands of DOM nodes We're talking about updating multiple DOM nodes dude, not a 3D rendering engine or a single ca
98.
▲
by
exogen
7y ago
That might be true, if this person were not most likely just making things up. Jasper_ is vastly overstating things if not outright lying. Updating that many elements is possible with canvas maybe, but DOM nodes, no. Here's a dead simp
99.
▲
by
exogen
7y ago
The extracted vocals sound great! But the resulting accompaniment tracks I've heard so far (tried on a handful of songs) aren't of usable quality for most purposes where you'd want an instrumental track – they're too son
100.
▲
by
exogen
7y ago
There's an accompanying blog post here, surprised it's not higher: https://design.lyft.com/re-approaching-color-9e604ba22c88
101.
▲
by
exogen
7y ago
For completeness sake, it's also possible to get the number of code points in JavaScript: Array.from('<emoji here>').length or equivalently: [...'<emoji here>'].length
102.
▲
by
exogen
7y ago
So it's caused by a reference to `print` not being what they expected. The create-react-app project maintains a great list of "confusing browser globals" for exactly this situation! https://github.com/facebook
103.
▲
by
exogen
7y ago
No and no.
104.
▲
by
exogen
7y ago
Well they don't claim any ownership, so: problem solved! :) There's a benefit to having the option to transfer ownership though when it makes sense: some projects become a support burden, or incur hosting costs, or have just los
105.
▲
by
exogen
7y ago
In my personal experience this effect has much more to do with expectations than compensation. As soon as it's my job to work on something, and there are deadlines and expectations looming, all of a sudden I'm more interested in
106.
▲
by
exogen
7y ago
There's a big difference in paying for something because you need it done and paying for something you don't even necessarily want but someone did anyway. If you're thinking about "what did this software cost?" an
107.
▲
by
exogen
7y ago
Before (the status quo): $0. Now: $20/hour. If that's devaluing something, I would like to devalue my worth by several orders of magnitude please. :)
108.
▲
by
exogen
8y ago
In addition to everyone else's comments, there's another big problem: browsers treat setTimeout delays as very loose suggestions. If you're scrolling when one of these timeouts is set, or one starts and then you start scrolli
109.
▲
by
exogen
8y ago
There's also a big piece that people who see useContext/useReducer as a replacement for Redux usually miss: server side rendering. The Redux store lives outside of the React component tree and has a getState() method to capture
110.
▲
by
exogen
8y ago
React adds one layer of indirection such that it's spitting out "a description of what to render" rather than "a string of HTML to render" directly. That means the same code can be used both on the server and clie
111.
▲
by
exogen
8y ago
The actual reason is far more boring: https://news.ycombinator.com/item?id=19137302
112.
▲
by
exogen
8y ago
Bug: the code you posted will always do nothing.
113.
▲
by
exogen
8y ago
Not only that, but classes are at odds with advanced render scheduling like React is moving towards (concurrency, prioritized rendering, context switching, bailing out of renders, etc.). With a class instance, what happens if you need to ba
114.
▲
by
exogen
8y ago
I am the grandparent, and never mentioned anything about state. Not sure why state matters. Declarative CSS rules have effects. The scope of those effects can be both unlimited and unintended, and you can't "opt out" of being
115.
▲
by
exogen
8y ago
No.
116.
▲
by
exogen
8y ago
React is greater than 4 years old, and people mostly use it for the nice authoring experience, not to dick around with CSS isolation problems.
117.
▲
by
exogen
8y ago
Note that npm also supports having multiple versions of the same package installed just fine. The problem: I use X to create an object with library A v1.0. I use Y to create an object with library A v2.0. These objects are not necessarily c
118.
▲
by
exogen
8y ago
I'm happy that just prefixing things is working for you. I don't typically have problems on smaller projects. But I've also been writing CSS since 1997. I've deployed CSS to sites like walmart.com, nfl.com, mlb.com, star
119.
▲
by
exogen
8y ago
I believe this is a result of it using the "CSSOM" browser APIs for speed in production. Unfortunately, browsers apparently haven't figured out how to make such styles editable yet. It's definitely a limitation of certai
120.
▲
by
exogen
8y ago
What dependency system anywhere on earth is free of the problem of "two things require different versions of the same library"? I don't see the relation to JS at all. I've had this problem with JavaScript-before-npm-exis
More ›