Live data from Hacker News

You might not need JavaScript

youmightnotneedjs.com

131–140 of 254 posts

Re: You might not need JavaScript

#131
post #110

Earlier quoted context omitted.

All you need is this motherfucking website: http://motherfuckingwebsite.com/

Actually you need a tiny bit more: http://bettermotherfuckingwebsite.com

And a very tiny bit of additional polish (which would make a good basis for, say, browser defaults), IMO, even better: https://codepen.io/dredmorbius/full/KpMqqB/

14 style rulesets.

Re: You might not need JavaScript

#132
post #9

The you don't need jQuery website had a concrete use case - you need not include an entire library into your website for some simple tasks which makes your website faster. Though, this site is cool in showing the power of CSS, I am not sure if there is any specific advantage of using CSS over JS to design tabs, sliders, etc. Just use the best tool for the job!

The Tor web browser disables most (if not all?) Javascript by default as a security measure. Avoiding Javascript is an advantage if you want your website to be accessible to Tor users. If your website only handles basic things like form inputs and it breaks when Javascript is disabled, then you have not made it accessible.

I think by now it's pretty safe to say most websites don't care about the tiny % of people using Tor or disabling JavaScript.

Re: You might not need JavaScript

#133

Earlier quoted context omitted.

Actually you need a tiny bit more: http://bettermotherfuckingwebsite.com

Getting there! https://bestmotherfucking.website/

If I was the owner of motherfucking.website I would also take requests at better.motherfucking.website and best.motherfucking.website.

Re: You might not need JavaScript

#134
post #57

Earlier quoted context omitted.

> the alerts can't be styled and the behaviors can't be controlled It's not clear to me whether that's a problem. Isn't consistent UI a good thing? Isn't it faster to fill the forms correctly if alerts always appear in the same way?

Not really. The errors on Firefox at least, just say "Please match the requested format", which doesn't tell the user where they went wrong for potentially complex requirements.

You can use the title attribute to customise the error message.

Re: You might not need JavaScript

#135
post #57

Earlier quoted context omitted.

> the alerts can't be styled and the behaviors can't be controlled It's not clear to me whether that's a problem. Isn't consistent UI a good thing? Isn't it faster to fill the forms correctly if alerts always appear in the same way?

Not really. The errors on Firefox at least, just say "Please match the requested format", which doesn't tell the user where they went wrong for potentially complex requirements.

[deleted]

Re: You might not need JavaScript

#136
post #25

Earlier quoted context omitted.

Safari is the new IE6, stop supporting it and let it die. It will not get any better anyway. If most of your users are on iOS, then make an app for them, it's what Apple also want you to do...

"Safari is the new IE6, stop supporting it and let it die." I can only assume you never went through the pain that IE6 delivered... It has been some years now but I still get nightmares about it. It literally made me question at one time if I didn't made the wrong choice to focus on web development. Apple may be dragging its feet when adapting new api stuff, but the situation is by no means comparable as what the sit…

IE6 wasn't so bad. It could do everything in 2001 that practically every site needs today, and pretty intuitively if you didn't also support other browsers. But dealing with emerging "standards compliant" browser bugs alongside "the de facto standard" IE6 bugs in the same code, and eschewing table layout before CSS was up to the task, that was a nightmare.

Re: You might not need JavaScript

#137

If you use React and inline styles, you might not need HTML and CSS: https://vimeo.com/116209150 Also, if you want the benefits of inline styles, but need media queries and the like, check out Radium: npm.im/radium

Pretty much what I do. I am also enjoying using Aphrodite [1] these days.

[1] https://github.com/Khan/aphrodite

Re: You might not need JavaScript

#138

Earlier quoted context omitted.

The Tor web browser disables most (if not all?) Javascript by default as a security measure. Avoiding Javascript is an advantage if you want your website to be accessible to Tor users. If your website only handles basic things like form inputs and it breaks when Javascript is disabled, then you have not made it accessible.

I think by now it's pretty safe to say most websites don't care about the tiny % of people using Tor or disabling JavaScript.

That doesn't make it laudable, or even defensible.

Re: You might not need JavaScript

#139
post #56

> JavaScript is great I've never heard somebody say that. Can you elaborate?

It's powerful, flexible, supports classical and functional paradigms and can handle input validation and transformation better than most languages with less code. It's the only reasonable cross platform client/server language which is well supported.

I can say this for (nearly) any dynamic language like python or ruby. Your second statement is plain wrong however. Take clojure for example which compiles to java bytecode and javascript (cljs) seamlessly. You seem to be a victim of the Blub paradox.

Re: You might not need JavaScript

#140

Earlier quoted context omitted.

Actually you need a tiny bit more: http://bettermotherfuckingwebsite.com

Getting there! https://bestmotherfucking.website/

The first two were actually making a good point. This website (yours, presumably) is just jumping on the bandwagon and sticking an affiliate link in it. I'm not against affiliate links, but this site lacks substance.
Post reply on HN