Readit News logoReadit News
spenuke commented on How to start a React Project in 2023   robinwieruch.de/react-sta... · Posted by u/antidnan
rco8786 · 3 years ago
Does anybody else think it's extremely damning that a mature framework such as React still has no agreed up on way to start a project? One of React's initial selling points was that it was a library, not a framework! React is unopinionated! Etc. Perhaps some opinion might have been better, in hindsight.

How is `react new` not a thing?

spenuke · 3 years ago
It's the same story with Express as a web server framework for Node.

I've always felt that the biggest problem with the Javascript ecosystem is that it's entirely too preoccupied with syntax. Remember CoffeeScript!? Some of the most influential forces in the community can waste entire years bikeshedding some syntactic thing that is mostly a matter of personal aesthetics. And this trickles down to the grunts trying to ship a product.

It's a fundamental drawback to Javascripts other strengths. And that's the reason it's so easy to find Express apps that are hot garbage. It's one of the most enduring myths that If you know Javascript, you can write a Node app.

It only works because software has been such an economically productive force, that having thousands of professionals spending weeks deciding whether semicolons are good or bad, or fighting their webpack configs, or migrating for loops to array methods... whatever... it still makes money at the end of the day.

spenuke commented on Building a patient monitoring system with Go and Vue in 3 days   kasvith.me/posts/how-we-c... · Posted by u/astdb
fludlight · 6 years ago
What's CMS? Centers for Medicare and Medicaid Services?

https://www.cms.gov/

spenuke · 6 years ago
Yes.
spenuke commented on A Map of Mathematics   quantamagazine.org/the-ma... · Posted by u/theafh
_ylmx · 6 years ago
Does anyone have suggestions for good books on the history of Mathematics?
spenuke · 6 years ago
For a very informal tour, The Three Body Problem by Cixin Liu is a science fiction novel where the history of mathematics, physics, and computation play a large role. So much so that I think it puts many people off the book and its entire trilogy.
spenuke commented on TLA+ model checking made symbolic   blog.acolyer.org/2019/11/... · Posted by u/feross
im_down_w_otp · 6 years ago
We use TLA+. There's nothing particularly magical about TLA+. There are a variety of modeling languages and model checking toolkits out there. I've yet to encounter someone in industries that have commonly adopted model definition & checking who uses TLA+. It's popularity seems highest among folks in newer SaaS/IT arenas than elsewhere.

More often I run into folks using SCADE's model checker. Tied for a distant 2nd, I'd say I've run into more folks who work with NuSMV, CADP, and mCRL2 than TLA+. This could also be mostly sample bias, and it's worth noting that the folks who use any of these things are in the very extreme minority of architects & developers that I speak to in automotive, med. tech., industrial automation, etc.

Though, like I said, we use TLA+. Not for any particularly good reason than it was a sufficient tool among the variety of comparable tools for what we needed to do, but I expect that if we had to go back and do it all over again we'd have selected something else. The specification language has some annoying warts, the checking performance isn't comparatively very good, and the provided IDE works in almost exactly the opposite way any of us wish it would work. To the point that one of our engineers figured out how to wire it all up through Emacs so we could stop monkeying around with TLA Toolbox for 90% of the work. Of course, everything has problems, so TLA+ isn't notoriously different here. We've just used it in anger more than other things.

For whatever it's worth, I also used to be an Erlang developer and used to play around a bit with McErlang, which I think might be a dead project now. However, there's an active project called Concuerror (https://concuerror.com/) which kind of covers the same domain. I don't know how well it works or what its level of maturity is, but it is very interesting in this one very important regard... it's model checking against your actual program implementation. That's an enormous and fantastic difference. Model conformance of concrete implementation to your design (and checked) model is an enormous problem, and tools which can close or remove that gap can be enormously valuable. What I don't know is the level of sophistication of Concuerror, nor if it is able to check for the kinds of properties you care about in your systems.

spenuke · 6 years ago
Did you all ever open source your emacs tooling? I’d like to see that.
spenuke commented on How to use array reduce for more than just numbers   jrsinclair.com/articles/2... · Posted by u/jaden
kace91 · 7 years ago
At my current project we try to do everything as functional as possible (we're backend developers using node).

After a year or so of trial and error, we have pretty much stopped using reduce. The reason is that it pretty much always causes the code to be far less readable, specially for new devs that come from more object oriented approaches.

With the .Map, .foreach and .filter, methods we don't usually have that problem, people get the hang of them quite quickly and find them more elegant, but reduce always seem to require to stop for a few seconds to learn what it's doing.

spenuke · 7 years ago
I work on a similar team, with a mix of people who want to use functional styles and those who want something more imperative.

I lean toward the pro-functional style, but I also put a few strong constraints on when to use reduce. Namely, I would almost never use it in cases where I either want to (a) mutate something other than the accumulator or (b) include more than two branches of control flow in the reducer function.

This kind of goes for all the functional array methods. Many people are tempted to use them simply as alternate syntax for iterating through the array (i.e., a simple loop), where the loop body could contain several statements -- i.e., data mutation side effects, taking different execution paths based on certain conditions, etc. The functional style is way less clear in this sort of code.

The benefit of the functional style in the context of javascript array methods is when you can see at a glance what the shape of the resulting value is with respect to that of the source array. This is usually best done when the body of the reducer/mapper/filterer is a single expression.

spenuke commented on Taleb Says Fed Should Do 'Minimum Harm' [video]   bloomberg.com/news/videos... · Posted by u/ryansmccoy
pfortuny · 7 years ago
No: he does not say that statistics are useless. He says that the assumption of normality does not hold in real life: fat tails and the absence of means are ubiquitous. That is all the “black swan” means and how he got rich: taking risks which are nonsense under normal distributions but not so under, for instance, the Cauchy distribution.
spenuke · 7 years ago
Thanks. Ok, so is he creating strawmen everywhere, then? I know people working in government, biotech, climate research, and none of them seem to think that the normal distribution is the only model out there, or that the mean is a very meaningful (no pun intended) statistic.
spenuke commented on Taleb Says Fed Should Do 'Minimum Harm' [video]   bloomberg.com/news/videos... · Posted by u/ryansmccoy
ixtli · 7 years ago
Honestly Taleb's cult is pretty disconcerting.
spenuke · 7 years ago
Can somebody please ELI5 his whole phenomenon? I don't really understand who are the targets (other than Nate Silver) of all his polemic. From my limited exposure, he's basically making age-old conservative points, arguing that the Enlightenment ideal of human knowledge has strong (but unidentified) limits.

Why is he so popular? And how did he get so rich on Wall Street if he just thinks randomness blows all the statistical experts out of the water? I know I'm missing something.

spenuke commented on The Best History Books 2018   historytoday.com/history-... · Posted by u/benbreen
douglaswlance · 7 years ago
Anyone have a suggestion for American history? I am looking for something that focuses on how America grew into the leading world power in such a short amount of time comparatively.
spenuke · 7 years ago
Five Books just published a list this week. https://fivebooks.com/best-books/dr-patrick-porter-on-the-ri...
spenuke commented on Postgres data types you should consider using   citusdata.com/blog/2018/0... · Posted by u/okket
derobert · 7 years ago
When a database is just functioning as your (relatively monolithic) application's data store, validation on the app side works well. The app is the primary—maybe only—product.

But if you have multiple apps sharing the same data, or the app is a bunch of different things from many years glued together, etc., then there is no longer "the" application side. You'd have to write validation on multiple application sides, and make sure they all agree. The data is at this point often more important than a single app.

Even with single-app data stores, if you ever have to use the SQL prompt directly (say, to do a one-off change that it doesn't make sense to write an app feature for, or time doesn't permit doing so) it's nice to have all the constraints specified in the database.

spenuke · 7 years ago
100% agree with this here.

I have had to push for leveraging postgres for data validation (including typing columns with enums where applicable), and sometimes it's hard to convince people, but all you have to do is (a) poke around your existing data and find cases where you have junk because of some out-of-band process that created data without using your main app's validation, and (b) do a couple out-of-band things like an ETL or two and see how it saves you from creating junk.

I don't know where I picked this adage up, but it's also something I constantly think about:

Your data will outlive your application code.

IME, if you value the data's integrity, it's not really a question whether you should be pushing validations down to the db layer.

u/spenuke

KarmaCake day274July 11, 2013View Original