noscript

Trevor
2 min readMar 31, 2020

How do I write a webpage that works for users without js enabled?

These are my notes as I find out, enjoy!

Why do people have javascript disabled?

“People may have JavaScript turned off to improve speed and security, and users often face network issues that prevent loading scripts. Moreover, third-party scripts (ads, tracking scripts, browser extensions) might break your scripts.” https://developer.mozilla.org/en-US/docs/Learn/HTML/Howto/Use_JavaScript_within_a_webpage

So what can I do about it?

Use a <noscript> tag.

The <noscript> element defines a section of HTML to be inserted if a script type on the page is unsupported or if scripting is currently turned off in the browser.

Is “noscript” supported across all major browsers?

It seems pretty well supported as of this writing.

How do I use it?

One way is to tell users you don’t support javascript

<noscript>This webpage requires

--

--

Trevor
0 Followers

Hello! My stories are a series of notes as I journey along learning new things. I hope you enjoy!