[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: force display of <noscript> content
From: |
Ian Kelling |
Subject: |
Re: force display of <noscript> content |
Date: |
Wed, 12 Oct 2022 15:00:09 -0400 |
User-agent: |
mu4e 1.9.0; emacs 29.0.50 |
Yuchen Pei <hi@ypei.me> writes:
> Hello,
>
> Currently, librejs filters all html and js requests / responses, and
> accepts / edits / rejects accordingly. It forces the display of
> <noscript> element content only when an inline script / event handler
> etc on an html has been modified. This can cause problems when librejs
> leaves html unmodified, but blocks some external scripts. An example is
> certain versions of discourse forums, like [0][1] and sometimes the fsf
> member forum, with librejs the browser may display a blank / broken
> page, but they render fine in browsers not supporting javascript like
> eww and lynx.
>
> [0] https://discourse.haskell.org/
> [1] https://emacs-china.org/
>
> I was thinking about what to do with this. I can think of a few options
>
> 1. Add a button to allow the user to manually force noscript display
> until the next (re)load. This is what I have done in [2].
>
> 2. Add a more persistent user option, which when enabled, make librejs
> reject all scripts when a noscript tag is present.
>
> 3. Something in between: a per-site / url option to force noscript
> display.
>
> [2]
> https://git.savannah.gnu.org/cgit/librejs.git/commit/?h=noscript-toggle&id=b849b8d461479cf6530c77b97b094807840ce0d7
>
> A few relevant questions:
>
> 1. Do developers ever sneak scripts between <noscript> tags?
>
> 2. Does it make sense to reject all scripts, free or nonfree, when
> opting for noscript display, assuming sites generally use <noscript>
> to offer a version when *all* scripts are blocked? Otherwise there
> may be duplicate content on a web page if some scripts are accepted
> and <noscript> content is displayed.
>
Great questions. I don't know the right answers. I think some
experimenting should be done. I've noticed noscript not showing
<noscript>, but I don't know if that is what it /always/ does, it would
probably be good to understand exactly what it does as a point of
reference for what someone else determined was reasonable behavior.