"your website doesn't work without javascript"

https://cyberpunk.lol/@vantablack/114756539405197662

18 points · 73 comments · view on lemmy.world

73 Comments

Piatro@programming.dev · 66 pts · 188d (9 replies)

Got to disagree there. Websites should work without js. Sure it shouldn't have fancy animations or whatever but I should be able to read it.

schnurrito@discuss.tchncs.de · 33 pts · 188d (7 replies)

Depends on what kind of website we are talking about.

If it's a website whose purpose to display an article or images or similar, I agree with you.

If its main purpose is something that requires interaction by the user (i.e. it's a "web app"), then it's not a reasonable expectation that it should work without JS, and then I agree with the OP.

ICastFist@programming.dev · 15 pts · 187d (5 replies)

Even "web apps" don't necessarily need javascript. Is a forum a web app? It has plenty of user interaction and forums without javascript have existed since before HTML. Even stuff like Mastodon doesn't necessarily need javascript, it can work as static pages.

schnurrito@discuss.tchncs.de · 5 pts · 187d

I agree that these are more of a continuum than a binary.

GraveyardOrbit@lemmy.zip · 1 pts · 187d (3 replies)
[ removed ]
ICastFist@programming.dev · 7 pts · 187d (2 replies)

There’s a reason nobody uses forums anymore and it’s because static content feels and is extremely dated

Nah, it's more because they want everything in the same place. Reddit and Discord became the "internet forum" - 1 account, 1 site/app, every community and discussion you need. Same for Roblox

The other reason is the dopamine hit of endless doomscrolling. If you think about it, most online interaction is: upvoting/liking, commenting, sharing; which I would argue is just a bare minimum of interactivity.

GraveyardOrbit@lemmy.zip · 2 pts · 187d (1 reply)
[ removed ]
ICastFist@programming.dev · 2 pts · 187d

Of the two, only discord actually really needs javascript to work as intended on a browser. Reddit, though? It's still a static web forum, you don't lose much browsing old.reddit instead of www.reddit.

Besides, I never argued those two are not "rich web applications", my point was that "static web content looks dated" wasn't the main driver for people to move into centralized platforms.

pinball_wizard@lemmy.zip · 2 pts · 186d

If its main purpose is something that requires interaction by the user (i.e. it's a "web app"), then it's not a reasonable expectation that it should work without JS, and then I agree with the OP.

Web apps predate JavaScript by many years. The kids writing websites these days just don't know how.

socsa@piefed.social · 5 pts · 187d

E S O T E R I C

SpaceNoodle@lemmy.world · 43 pts · 188d (9 replies)

I remember when webservers served content, and didn't just pass me megabytes of bloated spaghetti and say "here, YOU run this."

kalkulat@lemmy.world · -4 pts · 187d (8 replies)

Static pages are fine if you don't want to interact with them. Books have been around since the 1400s.

But they won't let you search a whole book for particular name, place, term. Or take your input and calculate answers for you? Or let you create music or art? etc. etc.

fushuan@lemmy.blahaj.zone · 13 pts · 187d (5 replies)

You don't need that to search. In fact, you send the search query and get the response back.

Yes, they let you search the term, it's called asking the librarian to tell you which page.

Forms that send a post request to the server and the server serves you the page with the answer is how it works. Ajax is cool, sure, but don't tell us lies, or don't talk with confidence without knowing.

RaphaelSchmitz@feddit.org · 1 pts · 185d (4 replies)

You ask the librarian how often the word "arrow" is in Lord of the Rings, and they have to tell you?

mech@feddit.org · 1 pts · 185d (1 reply)

Not sure what your point is, but that functionality could be built into a website without running any code clientside.

RaphaelSchmitz@feddit.org · 1 pts · 184d

My whole comment was that I'm not sure what the point is, because that's not how it works in reality. So if you actually want to know, you'll have to ask the author of the comment above me.

fushuan@lemmy.blahaj.zone · 1 pts · 184d (1 reply)

I was trying to make the best of what I could with the bad example they provided...

But as they already responded you, before Ajax was a thing term searches were done via forms. I still state that it has it's uses, but let's not pretend like the universe was born with javascript.

RaphaelSchmitz@feddit.org · 0 pts · 184d

But if the best of what you can do with it doesn't make sense, then why do it? It's not like it's helping, just distracting from the parts that DO work.

And kind of the same thing again: The universe wasn't born with forms, either.

When we did a project for a redesign of our web app at work, when I showed stuff to the UXer he said "I see this is designed by a programmer. Because a programmer says: But it works."

And indeed, that is how all of the comments I read here feel; that things like a denounced search are just irrelevant toys, instead of a solid part of the toolkit of a professional modern developer.

SpaceNoodle@lemmy.world · 13 pts · 187d (1 reply)

Y'all forget about forms? And, uh, programs?

Droechai@piefed.blahaj.zone · 5 pts · 187d

I remember doing indexes in html with hyperlinks

NigelFrobisher@aussie.zone · 34 pts · 187d (1 reply)

I hate this cursed timeline where even finding out the opening hours of a restaurant needs to load half a dozen frameworks.

Canconda@lemmy.ca · 6 pts · 187d

I hate the padded aesthetic of everything. Like I use an old.reddit clone on lemmy cuz I just wanna access the content ffs.

x00z@lemmy.world · 27 pts · 187d

Good developers can write websites that have non javascript fallbacks.

For example, a form to save settings with a save button, but when javascript loads it hides the save button and makes it automatically save when you toggle options.

ICastFist@programming.dev · 17 pts · 187d (16 replies)

This woman is part of the problem of the current internet. There are only a few sites that make sense to only work with JS enabled and federated social media is NOT one of those. Wanna know why? Because all the JS bullshit is just to make shit "pretty". The data isn't - rather, should NOT - reside entirely in the JS.

EDIT - To make matters worse, the site in question is this - https://bestestmotherfucking.website/ ; which is "inspired" by Motherfucking Website and Better Fucking Website. I'm thinking this is just trolling and we fell for it

gabboman@gabboman.xyz · 2 pts · 187d (13 replies)

What have you done to say that federated social media doesn’t need js

mech@feddit.org · 2 pts · 185d

old.feddit.org works without Javascript, and the user experience isn't any worse than on the main frontend.

ICastFist@programming.dev · 2 pts · 187d (11 replies)

Do you need javascript to fetch content? No.
Do you need javascript to send content (comments, posts, reactions)? No.
Does federated social media require immediate page updates without refreshing the entire page? No.

Example: https://tap.resistant.tech/sarah/posts/1749417193

gabboman@gabboman.xyz · 3 pts · 187d (8 replies)

Is it easy to have a good user experience without js? No

ICastFist@programming.dev · 5 pts · 187d

The correct answer is: depends on what the user (or the main dev) considers good user experience. Is a clean, fast loading page good UX? I would personally say yes. It's much easier to have that without JS than with. Would everyone look at that linked example I gave and say "yes, this is good UX"? No, I've no doubt a lot of people would feel it looks too barebones to "feel good".

rain_worl@lemmy.world · 2 pts · 106d (4 replies)

YES!!! YES!!! IT IS EASY!!! JS MAKES IT WORSE!!!!

gabboman@gabboman.xyz · 1 pts · 106d (3 replies)

@rain_worl@lemmy.world

no its not. stop falling for snakeoil

blackratbighat@app.wafrn.net · 1 pts · 106d (1 reply)

@gabboman@gabboman.xyz @rain_worl@lemmy.world

What are your opinions (both of you) on HTMX?
It needs JS to work but the whole idea is that you stop dealing with the JS

gabboman@gabboman.xyz · 1 pts · 106d

@blackratbighat@app.wafrn.net @rain_worl@lemmy.world

Im an angular person (youve seen wafrn haha)

I do think htmx was a cool idea tho

rain_worl@lemmy.world · 0 pts · 106d

????????

november@app.wafrn.net · 1 pts · 106d (1 reply)

@ICastFist@programming.dev @gabboman@gabboman.xyz

Bro, yes is it. Look at Brutaldon.

aoeuidhtns@app.wafrn.net · 1 pts · 106d

@november@app.wafrn.net @ICastFist@programming.dev @gabboman@gabboman.xyz

yup!

goog@gabboman.xyz · -1 pts · 106d (1 reply)

@gabboman@gabboman.xyz @ICastFist@programming.dev

to the third one yes it requires, it fits right into my flow that i can just peek into a tab to see what's new in my feed while i'm doing something else, instead of hitting refresh and waiting until the page loads (and on a bad day that wait is long)

js for all the flack it gets, saves my time when i'm making a personal (static) website and i don't want to copypaste the same snippets of html into each file, while i can just use a js script to display the contents on several pages

maybe you should be a bit more open to feedback from an average user who's supposed to adopt your wonderful work, because with other nerds you will only get so far

and if you don't care about the average user, then do not comply that the adoption of your wonderful creation is pitifully small and be upset that no one cares about ""ethical"" software or whatever

ICastFist@programming.dev · 1 pts · 104d

to the third one yes it requires, it fits right into my flow

Your use case requires immediate page updates without refresh. Federated social media does not. Besides, Phoenix Framework can update the contents of a page without refreshing it, it even works with javascript disabled. I suspect other frameworks that use websockets can achieve that, too.

maybe you should be a bit more open to feedback from an average user who’s supposed to adopt your wonderful work

none of this is my work, my complaint is that people completely disregard optimization and sometimes even usability because "this framework is so cool!" - so long as your computer is high end. I've had my browser completely freeze the first time it opened some misskey instances, something that happens whenever the javascript is eating up way more than it realistically should.

If you really think about the average user, their computers and phones are mid to low range, topping at 8/3GB RAM (PC/Android) and are running a hundred background programs and processes because they don't know any better. Developing with the low end in mind ensures best usability, something that the majority of people developing with JS don't care at all.

RaphaelSchmitz@feddit.org · 2 pts · 185d

To make it "pretty"? That's more CSS I would say, and JS would be more about UX.

Which I haven't seen anybody here mention. Which is kinda giving antisocial nerds with hobby projects? I mean, in professional development you learn very quickly how ux is correlated to helpdesk tickets.

Like, we can talk about technical purity excercises all day, but code doesn't exist for its own sake.

november@app.wafrn.net · 1 pts · 106d

@vantablack@lemmy.blahaj.zone @ICastFist@programming.dev

"This woman is part of the problem of the current internet" is a wild thing to say about a funny joke website

nykula@piefed.social · 17 pts · 188d (2 replies)

JavaScript has been my favorite language for a decade. Still, I try to make websites server-rendered so that they can be read if my code fails to load or execute. For example, there are power outages in Ukrainian cities for most of the day because of the war. When there's no power, there's still 4G for a while but it switches to economic mode and slows down to a crawl. The websites of the monopolist energy company require a lot of JavaScript. It often fails to load for me during the outage. It's also not keyboard-accessible because of how its JS is implemented (I won't image I'd do better, they have a team while I'm a solo programmer, but I try and they don't). For me to see when there will be electricity at what place and plan where to go study and work, I have to rent a VPS, scrape their website and show me a static table that doesn't require JS to load. Some code to see what I mean: https://codeberg.org/nykula/powerup

dan@upvote.au · 4 pts · 188d (1 reply)

JavaScript has been my favorite language for a decade. Still, I try to make websites server-rendered so that they can be read if my code fails to load or execute

Have you tried Astro? It's good for exactly this. You write Astro components that look a little bit like React components, but they're all rendered either during the build (when using static site generation) or server-side.

You get the developer experience of a modern JS framework, with the output of a static site with minimal JS.

nykula@piefed.social · 5 pts · 187d

Yes, I tried multiple popular SSR frameworks and use one at work. As a hobby, I've been making my own SSR framework that is much more minimal, based on Preact, Valibot, Vite, node:sqlite, URLPattern, gettext.js and a few companion libraries. (But components look more like old-school Mithril than React because no JSX extension, just standard JS.) I want its node_modules to stay below 200 MB and to pick such dependencies that the apps built with it can be included in Debian repositories and potentially FreedomBox. Hopefully I'll be ready to make a fedi post about it next month.

mmmm@sopuli.xyz · 17 pts · 188d (11 replies)

So if for any chance you can't use JS (outdated browser, outdated system, text-based browser, JS disabled by an admin, JS won't load, assistive technology) then... it's your fault?

Klear@quokk.au · 9 pts · 187d

Or what if you don't have internet? Is it your fault you can't access the website?

fruitcantfly@programming.dev · 9 pts · 187d (7 replies)
  • outdated browser - your fault, and a foolish thing to use considering the modern, online threat landscape
  • outdated system - your fault, and like above you probably shouldn’t connect to the internet with that thing
  • text-based browser - your fault, and it shouldn’t surprise anyone that websites break when you use a browser that misses major functionality
  • JS disabled by an admin - your admin’s fault. Go complain to them, not to anyone else
  • JS won’t load - depends on reason for why JS fails to load
  • assistive technology - depends on the reason; your assistive software may be broken or misconfigured, or the website fails to follow best practice
Droechai@piefed.blahaj.zone · 6 pts · 187d

Braille interpreters (think a row of nubs that raises up the relevant letter as it "reads" the page) used to have issues with some webpages unless you accessed them via text based browsers. No idea if they still struggle as much but text based browsing will always have a function and place

mmmm@sopuli.xyz · 1 pts · 185d

You missed the point completely, though - you should not expect every user to have a shiny updated browser in a shiny new machine using your website, and blaming them if they don't.

If you want your website being able to be used by most of users, you better cover all use cases. That includes providing non-js fallbacks. Not doing that and blaming the users instead is just ridiculous.

fushuan@lemmy.blahaj.zone · 0 pts · 187d (3 replies)

So, if a webpage fails to load of Firefox it's our fault for not using Chrome? Following your logic.

fruitcantfly@programming.dev · 3 pts · 187d (2 replies)

Well, if we’ re following my logic, like you claim, then it depends on why the page is failing to load in Firefox: Are you using an outdated version of Firefox or on an outdated system? Is Firefox missing major functionality? Has your admin disabled major functionality in Firefox? Won’t some part of the website load in Firefox and if so, why? Are you using assistive technology in Firefox and if so, is it broken, misconfigured, or does the website not follow best practice?

If it is for another reason, then it obviously depends on that reason

fushuan@lemmy.blahaj.zone · 2 pts · 187d (1 reply)

Nono, you expect people to use the most used versions of the tools. Firefox has such a low usage that using the "Firefox version" of the "browser" tool can be interpreted as using an "outdated tool". You clearly don't, and neither do I, but some people put the line in a different place than you do and I don't think it's fair to say it's their fault for it.

Sure, for webpages where the objective is to have advanced functionality I do get it, but for news/blog posts, documentation, government pages that should be as robust as possible... There are paces where accessibility of "outdated" tools must be considered.

fruitcantfly@programming.dev · 2 pts · 187d

According to your logic, I can't blame you for believing that "news/blog posts, documentation, government pages [...] should be as robust as possible", but you also can't blame anyone else for interpreting objectives and functionality differently, and drawing the line elsewhere. Your post is a rhetorical suicide, and there is no point continuing this line of argument

rain_worl@lemmy.world · 0 pts · 106d

text-based browsers must be first-class
ad-hoc browsers must be first-class
the harder it is to haphazardly spin up a web browser, the more monopolistic it is

Yaky@slrpnk.net · -1 pts · 188d (1 reply)

Also, if your browser does not support latest TLS and does not have latest root certificates, it's your fault. /s

Let me load HTTP without the S if I want to.

spartanatreyu@programming.dev · 6 pts · 187d

Let me load HTTP without the S if I want to.

No, that let's companies man-in-the-middle you.

ISPs literally couldn't help themselves inject ads and other scripts that lagged and broke everything on every website all to chase a few bucks.

HTTPS prevents them from doing that.

Bronzebeard@lemmy.zip · 17 pts · 187d

Nope. Fuck your site.

NaibofTabr@infosec.pub · 16 pts · 187d (2 replies)

So... there's a practical difference between rendering markup, which is handled by the browser engine and generally benign, and running executable script, which is frequently malicious.

Allowing your website to load JavaScript means that I'm allowing you to execute arbitrary code on my hardware. Hopefully the potential blast radius of any malicious code is limited by safety precautions in my web browser, but a web browser is not a security barrier and should not be relied on to protect the local system from malicious code downloaded from the Internet. The most pernicious and seemingly unavoidable behavior of JavaScript on most websites is device fingerprinting, and to get a better understanding of how much of a problem that is check out https://coveryourtracks.eff.org/

The simplest step to prevent a lot of this malicious behavior is to block executable script. This is not really a new thing on the Internet, as extensions like NoScript have been around for 2 decades and have millions of users. This should be anticipated by the web developer as a completely normal use case.

Competent web developers understand that they have privacy-conscious users who block external executable script as a matter of course. Your website(s) should be designed to account for this, and should at least render and display information in a readable way without needing to execute your un-vetted code on the user's system. Maybe some dynamic functions of the website don't work, but that's OK as long as the majority of the site is accessible. A JavaScript-dependent website is no better than a Flash-dependent website, in terms of security, privacy, and professionalism.

NoScript frames this as a consent issue, and that's probably valid:

NoScript enables consensual browsing: your browser, your choice!

ulterno@programming.dev · 2 pts · 187d

I am not even a Web Dev. Just made a little profile site, which I didn't even complete.
And I tested it without JS.

mech@feddit.org · 1 pts · 185d

Counterpoint: If I host a website on my server, I can do whatever the fuck I want (within legal limits). Unless NoScript users are a sizable fraction of my userbase or target market, it makes no financial sense to spend time or resources on developing a fall-back without Javascript.

epicshepich@programming.dev · 11 pts · 187d

JavaScript was my first language because my initials are JS. After spending some time on programming.dev and seeing how many people bitch about JavaScript, I wrote a Python templating engine to convert Markdown into static HTML with CSS. I have like 10 lines of JavaScript that pre-populates a selector based on the URI's query string, but that's it. I got a perfect score on my Lighthouse report (and learns it gives you confetti when you do).

It took some creative problem solving, but I discovered that I didn't need like 99% of the JavaScript or PHP that I was using. What I needed was mostly to get good at CSS.

JakenVeina@midwest.social · 10 pts · 187d (1 reply)

There's a difference between a website and a web app. Websites indeed should not require JavaScript to function. Web apps are a different beast where, yes, disabling JavaScript means you are opting yourself out of being able to use the app.

kalkulat@lemmy.world · 1 pts · 187d

Yes yes a thousand times yes! The web exists to enable interaction more than cracking open a book or magazine. If all you're after is blogs, sure, turn it off.

OfCourseNot@fedia.io · 9 pts · 187d (3 replies)

Fuck this.

The state of the web, and software in general, is fucking abysmal. And it is in no small part due to this kind of shit. You want this recipe/news/whatever? Here is a hundred mbs of frameworks, trackers, spyware...

What's even the point nowadays when every website, sorry, 'wEb ApP' is going to make me install their crappy app to give me full functionality? Then the app is just a web view (when not a wrapped full fledged web browser) to present their shitty web but with more privileges.

kalkulat@lemmy.world · -5 pts · 187d (2 replies)

The state of the web ... is fucking abysmal.

Like the whole rest of the world... that's the users' faults, not the developers.

OfCourseNot@fedia.io · 2 pts · 187d (1 reply)

No I'm not saying it's the developers' fault, they're not the people making these decisions, just building whatever they're paid for. But in this case it is this dev's own site, and they're defending their decision here.

The users..I don't know how much they (we) are to blame. We all end up succumbing to the pressure sooner or later, and even though I really wish more people would put a bit more of a fight, when I see myself using smartphones, lots of these apps, WhatsApp, windows at work... sometimes I think whether maybe the ones giving up early or just straight up embracing the crap are the wiser ones, because resistance does sometimes seem futile.

pinball_wizard@lemmy.zip · 1 pts · 186d

No I'm not saying it's the developers' fault, they're not the people making these decisions, just building whatever they're paid for.

That's fair and reasonable.

That said, I'm happy to also blame the developers.

I faced the same pressures, but I still learned my craft.

hector@lemmy.today · 6 pts · 187d (1 reply)

Isn't javascript the source of vulnerabilities in software? Enabling it is a security threat. This is victim blaming by whomever this woman is.

calcopiritus@lemmy.world · 6 pts · 187d

Basically everything is a security threat one way or another.

If you want other people to do things for you, it's a potential vulnerability, so if you don't want that, don't let people do things for you. But then don't complain that they aren't doing things.

Disabling JavaScript is a tradeoff, you trade off its conveniences for security and resource usage. But you can't have your cake and eat it too.

irelephant@lemmy.dbzer0.com · 4 pts · 187d (1 reply)

What is the site?
for like, a blog, I think that's an ok complaint to have.

ICastFist@programming.dev · 2 pts · 186d

I suspect it's this - https://bestestmotherfucking.website/

I also suspect both the site and that message are trolling

Mesa@programming.dev · 2 pts · 187d

Small world-view moment

VibeSurgeon@piefed.social · 2 pts · 185d

Progressive enhancement really is a lost art huh

kalkulat@lemmy.world · -4 pts · 187d (2 replies)

Without JS, most webpages couldn't do 1/10th of what they do. There'd just be text and pictures. OK for fairytale books.

amzd@lemmy.world · 18 pts · 187d

Most websites are just text and pictures..

MadhuGururajan@programming.dev · 1 pts · 186d

how wrong you are. Most webpages don't have to do client side computation. Its all fancy ajax anyway.