News for hackers. Stuff that matters.
Re:A contentEditable, pasted garbage and caret placement wal... by underwater on Friday July 23, 2021 @11:21PM (#27938131)
Odd choice to use ClojureScript in a tutorial. The point of a tutorial is to convey information effectively. This is like a physics professor deciding to lecture in French because they think it sounds better.
Re:A contentEditable, pasted garbage and caret placement wal... by tobr on Saturday July 24, 2021 @12:54AM (#27938492)
That’s right, no one in France actually knows any physics, because it’s completely impossible to convey information effectively in French, and they just use it because they think it sounds good. Just like ClojureScript in tutorials.
Re:A contentEditable, pasted garbage and caret placement wal... by ajkjk on Saturday July 24, 2021 @02:36AM (#27938934)
the idea is that you're in front of an english-speaking audience.

The clojurescript makes this an absolute slog to read.

Re:A contentEditable, pasted garbage and caret placement wal... by boondaburrah on Saturday July 24, 2021 @07:42AM (#27940054)
If you /know/ you're in front of an english speaking audience and deliberately don't speak that language sure, but there's no specific programming language for HN. Hell, hackernews itself is written in a lisp.
Re:A contentEditable, pasted garbage and caret placement wal... by ajkjk on Saturday July 24, 2021 @12:26PM (#27942234)
That doesn't really matter, most web development is in Javascript and if you want to communicate to web developers widely you should use (something that looks like) Javascript.
Re:A contentEditable, pasted garbage and caret placement wal... by eitland on Saturday July 24, 2021 @06:32AM (#27939725)
I found it interesting, then remembered that in every single case (except maybe TypeScript) the new language is simpler only as long as you follow the tutorials closely. (Usually a mess of missing IDE support, missing documentation, big undocumented boilerplates etc).

That said, a number of those languages are interesting and great even of they aren't as simple as the tutorials make them look.

Re:A contentEditable, pasted garbage and caret placement wal... by marcellus23 on Saturday July 24, 2021 @07:18AM (#27939910)
You utterly missed the point.
Re:A contentEditable, pasted garbage and caret placement wal... by adrusi on Saturday July 24, 2021 @07:59AM (#27940155)
No, the parent comment's point was that some people use clojurescript, just like soms people speak French. Sure, most people who use clojurescript can read javascript, but most people (in Europe/NA) who speak French will also understand English. And yet we don't criticise profs of physics in France for lecturing in French.
Re:A contentEditable, pasted garbage and caret placement wal... by askonomm on Saturday July 24, 2021 @10:49AM (#27941408)
I wouldn't call what I write a tutorial per se, more of a "I went through this problem and this is how I solved it". And consequently, I went through this problem in ClojureScript. I even linked to the project I'm building, which is entirely ClojureScript. Perhaps ClojureScript isn't for you, and that's fine, but seems odd for me to criticize on the merit of language choice when you're on what is effectively a programmers forum.
Re:A contentEditable, pasted garbage and caret placement wal... by kryptk on Saturday July 24, 2021 @08:54AM (#27940512)
If this article was trying to get me to try ClojureScript, it had the exact opposite effect. Beautiful syntax to define a class had me at first, but then fell on its face when I saw that first "if" and compltely lost me with the gymnastics required to.. wait for it.. make one thing happen after another?

I just dont understand.

Re:A contentEditable, pasted garbage and caret placement wal... by tasogare on Saturday July 24, 2021 @12:42AM (#27938450)
Physics lessons are taught in French in France+... It's not because a programming language is not very popular that it shouldn't be used for a tutorial; on the contrary it can help building the network effort most of them rely on.

+ not only there but also in Québec, Switzerland, Belgium, a lot of African countries. Millions of people understand French as a first or second language. Moreover there is a lot of scientific literature in French, in particular in linguistics (the field was created in French, actually). I find your statement rather insensitive.

Re:A contentEditable, pasted garbage and caret placement wal... by underwater on Saturday July 24, 2021 @03:39AM (#27939107)
The implication to "French because they think it sounds better" is that they aren't speaking French for more obvious reasons.
Re:A contentEditable, pasted garbage and caret placement wal... by Zababa on Saturday July 24, 2021 @06:58AM (#27939823)
I'm French and I don't find the statement insensitive at all. English is the de-facto language of the web, trying to deviate from that is making it harder for people that read your content. This is not a value judgement, there are lots of language with a beautiful history and culture, English included. But what's used the most and thus the most useful is a simplified version of English.
Re:A contentEditable, pasted garbage and caret placement wal... by adrusi on Saturday July 24, 2021 @08:01AM (#27940176)
Ok but you're mixing metaphors. No one's talking about writing web tutorials in French or teaching physics in Clojurescript.
Re:A contentEditable, pasted garbage and caret placement wal... by Zababa on Saturday July 24, 2021 @08:38AM (#27940385)
I'm not, JS is the most used language for frontend, and saying that using something else reduces the clarity of the article is perfectly valid criticism.
Re:A contentEditable, pasted garbage and caret placement wal... by bastawhiz on Saturday July 24, 2021 @05:35AM (#27939489)
Agreed, I largely gave up trying to understand what the code is doing. The message really gets lost unless you already understand clojurescript's flavor of React.
Re:A contentEditable, pasted garbage and caret placement wal... by damsta on Saturday July 24, 2021 @07:37AM (#27940021)
Agreed. I am grateful for the article, but the code was hard to read.