Skip to content
This repository was archived by the owner on Aug 2, 2020. It is now read-only.
This repository was archived by the owner on Aug 2, 2020. It is now read-only.

Remove dependency on Javascript for static pages #58

@jhaye

Description

@jhaye

Due to the nature of how federation works, you'll get yourself checking out a post's direct link to its static page to get the full conversation.

As the people of the Fediverse tend to be more technically inclined, a lot disable JavaScript by default on unknown domains as a security precaution. If a thread contains content warnings, there is no way to expand them, without having JavaScript enabled. As a result one has to allow the execution of JavaScript manually every time.

Here is an example page for examining the problem: https://harpy.life/@erinbee/102027937751106507

There would be benefits for non-technical people as well. Seeing how the size of JavaScript on the above example page exceeds 1MB, implementing this feature in pure HTML5 and CSS, would greatly reduce the required bandwidth for loading such a page and holding it in memory.
(There are other optimisations that could be done to images for example, but that is beyond the scope of this issue.)

An alternative implementation for CWs would be possible using HTML5's <details> and <summary> tags.
They are supported by every current major browser, except MS Edge - this will change in the future however.

Dynamic image loading would be trickier, but also doable I think. Maybe retaining some JavaScript for smooth functioning would be necessary here, but heavily reducing the amount of used JavaScript is definitely a possibility.

We would be trading all the benefits mentioned above for compatibility with MS Internet Explorer (any version). I'd say it's worth it.

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-accessibility(Affects) accessibilityA-security(Affects) security of software, to ensure it cannot be exploited in unintended waysC-main-viewMain view on web interface (component)E-medium (B)Medium (effort) to implementK-planning(Kind) is a general goal without concrete plansP-little (C)Little (impact) of change

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions