It didn’t work for me because I don’t load JS by default. I’ve gotten to where I use noscript 100% of the time. At first I couldn’t get over the added burden, but now I marvel at how we actually let web browsers load arbitrary code and run it on our machine without our permission.
You approximate this without JS by using invisible text. For example:
<p>echo hello<span style="display: inline-block; width: 0.1; height: 0.1; overflow: hidden;">; rm -rf /;</span> world</p>
Verified just now on Google Chrome Version 86.0.4240.80.
At first I couldn’t get over the added burden
Same here. But then, at some point you look over at a colleague’s screen and marvel at how much crap some sites load, and people put up with. I was looking for some information with a colleague and he found a site which showed a small rectangle with information which was decked on 3 sides with ads. I think there must’ve been 6 or 7 annoying ads surrounding the actual thing we were looking for!
His response: Oh, I don’t even notice those anymore.
Interactive HTML in our emails, what could possibly go wrong. This is a security nightmare lying in wait.
In my opinion, it’s too specific. We don’t have a tag for ClojureScript, there’s not even a tag for Clojure itself.
I’m using Lisp for Clojure and, in some cases, Java, because Clojure is run on JVM. I suggest you to use Haskell and maybe JavaScript.
I want to echo this. Also note: Tag’s are for specifically ignoring topics, does purescript warrant enough clout to be ignored?
As a long-time Clojure and Java programmer, I don’t agree with Eric here. Clojure is really just a Lisp targeting the JVM. If you like Lisp and you’re in a context where you can make use of the JVM (which is more places than I thought that would be a decade ago), it is an absolutely fantastic language. The combination of the most powerful language family on a ubiquitous runtime has lived up to its promises. I still prototype ideas in it even if I’m not going to use the code in production.
But Java is still very relevant, particularly for team-maintained large codebases, or where you really need to just write Java and Clojure is only adding noise. Good Clojure can be written and maintained by a large team, but it takes above-average Clojure programmers to do so and almost by definition you can’t have a large team (>10) of above-average Clojure programmers.
I don’t really follow the argument about large teams to be honest. My experience is that the problem with large teams has little to do with the choice of technology. Large teams introduce a lot of communication overhead, which makes for longer meetings, more emails, and more confusion where left hand doesn’t know what the right hand is doing.
Any large project can and should be broken down into smaller projects maintained by small teams. This is basically why microservice architecture has become so popular of late. Breaking things up is the best way to ensure that projects are maintainable regardless of the choice of language.
All that said, I do think that Clojure tends to work best when you have mostly experienced developers working on a project. It’s also not a great choice if you’re doing a lot of rapid hiring where you’re going to have to train a lot of new devs on the language. So, Clojure will never replace languages like Java in corporate environments.
I should probably have used a “large codebase,” which is more likely to need a large team supporting it. But you’re right, it’s not necessarily true. And that’s much more likely to occur with Java both because it’s a verbose language, and static typing enables it.