Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
m0meni
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
8 ms
·
31.
▲
by
m0meni
8y ago
JS with flow is way better than JS without flow. It prevents a whole class of errors, and you can basically opt-in and opt-out of the type system at any time if you're having trouble with it too. I wrote a blog post about it a while ba
32.
▲
by
m0meni
8y ago
That's an amazingly comprehensive answer. Thanks! So basically, when interacting with the outside world at scale, it's very hard to make any sort of guarantees about kind of data you're working with. And since you have to val
33.
▲
by
m0meni
8y ago
Could you elaborate on that last point regarding elixir and why type systems don't work for it? I couldn't find anything when I did a cursory search on google.
34.
▲
by
m0meni
8y ago
By target web, I meant compile to js with good interop. I.e. no languages like elm, purescript, reason, ghcjs, kotlin, etc.
35.
▲
by
m0meni
8y ago
I'm curious what the proponents of dynamic typing over static typing think about the recent push towards adding type systems to the two biggest dynamic languages out there: Python and JS.
36.
▲
by
m0meni
8y ago
With flow, you just gradually add typings and fix the resulting type errors. It's way easier to slowly integrate types file by file rather than rewriting everything. Moreover I think that at the time there were no statically typed lang
37.
▲
by
m0meni
8y ago
Also they're rewriting messenger in basically OCaml (Reason[0]) i.e. a statically typed FP language. [0]: https://reasonml.github.io/
38.
▲
by
m0meni
8y ago
https://en.wikipedia.org/wiki/Continuous_delivery
39.
▲
by
m0meni
8y ago
How'd the effective tax rate from Q3'17 go from 10% to 43% in Q4'17, and then back to 11% in Q1'18?
40.
▲
by
m0meni
8y ago
This misses the point of the article. It's short-sighted to say that he's reinvented CSP given that the entire concurrency model in Go is based around CSP, and the author is already aware of it. The article is more related to RAII
41.
▲
by
m0meni
8y ago
Nice library! This actually looks great. The syntax is a bit noisey, but tbh not any more than the actual proposal.
42.
▲
by
m0meni
8y ago
Fair point. What I was trying to express was that it seems like the JS ecosystem has really been pushing and encouraging functional programming in a big way, which speaks to your idea that more people have experience with it.
43.
▲
by
m0meni
8y ago
Pattern matching seems to be very trendy/popular right now. It's a big jump from JS, but https://reasonml.github.io has very nice pattern matching that you can use, and it integrates with the JS ecosystem very nicely.
44.
▲
by
m0meni
8y ago
I thought the title was kinda clickbaity, but it turned out to be a great article. Also the comparison to goto really effectively conveyed the point he was trying to make. I have two questions though: * Does anything else like this currentl
45.
▲
Notes on structured concurrency, or: Go statement considered harmful
(vorpus.org)
301 points
by
m0meni
8y ago
|
230 comments
46.
▲
by
m0meni
8y ago
I went through all of the languages you mention, and OCaml/ReasonML are what you're looking for (if you want a typed FP language). More than 50% of FB messenger is written in ReasonML so it's clearly a good long term investme
47.
▲
by
m0meni
8y ago
Good idea. I’ll try it.
48.
▲
by
m0meni
8y ago
It has been unfortunately.
49.
▲
by
m0meni
8y ago
How's this compare to https://github.com/pingcap/tikv ? It's a relatively new distributed KV store written in Rust that also is transactional and backs the new TiDB database.
50.
▲
by
m0meni
9y ago
http://2ality.com and everything else by the author including these books on modern JS http://exploringjs.com are gold.
51.
▲
by
m0meni
9y ago
This is pretty cool. From just reading the repo, it's built on this library I'd never heard of before called Yue[0] that seems to be similar to electron, but more lightweight. [0]: https://github.com/yue/yue
52.
▲
by
m0meni
9y ago
The other immer[0] of note is a JS library that gives you immutability with a mutable API i.e. you mutate your code as normal, but all changes are proxied to a copy, which is then returned as a result of your mutations. [0]: https:/&#
53.
▲
by
m0meni
9y ago
Just thought it was topical. Associating the two events so soon would be a stretch.
54.
▲
by
m0meni
9y ago
Wouldn't this swallow errors that you wouldn't want it to swallow? e.g. you try to access a property on a value that's null (which you think isn't null), and instead of getting an error, nothing happens. Idx[0] is a way
55.
▲
by
m0meni
9y ago
This is really cool. I was wondering what the difference between this and deeplearnjs[0] were, and turns out it's the same thing. Between this, and propelml[1] (from the creator of node.js), it seems like ML in the JS ecosystem is star
56.
▲
by
m0meni
9y ago
I'm curious that with the addition of APIs like forwardRef, if it wouldn't make sense to just add some HOC helper that does the HOC ceremony for you. For example, if you look at withRouter[0] from react-router 1. you need to set t
57.
▲
by
m0meni
9y ago
Summary: * Context overhaul that makes it way easier to pass state/props down multiple levels of components. Uses function as a child for the API * Adds React.createRef function to create refs. Creating refs through callbacks is still
58.
▲
by
m0meni
9y ago
For the first two examples, there's some unfamiliar syntax because they added Flow[1] typings to the examples (not TypeScript as other comments are suggesting). What about the syntax do you find confusing? The rest is all just ES6 + cl
59.
▲
by
m0meni
9y ago
Also add to that the huge amount of libraries available, great tooling, Flow and Typescript, and, even though it's kinda contrary to your point, all the compile-to-js languages that can leverage the JS ecosystem.
60.
▲
by
m0meni
9y ago
But how often do front end applications have performance critical code that operates on the DOM? Even then, it's more likely that if you need to render something that requires that much processing power it'd make more sense to use
More ›