Problem/Motivation

The .js class is added on every page where drupal.init.js is loaded for 'styling', this results in a style recalculation for the entire page.

We have the .js-hide and .js-show classes. Not sure why anyone would need to style anything differently purely depending on whether there is arbitrary javascript on a page or not.

Steps to reproduce

Proposed resolution

Remaining tasks

User interface changes

Introduced terminology

API changes

Data model changes

Release notes snippet

Issue fork drupal-3587863

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

catch created an issue. See original summary.

catch’s picture

Status: Active » Needs review
Issue tags: +Needs change record

Will need a change record but would be good to know if I've missed something or not.

I think this is probably detectable in a chromium performance trace although not sure how easy to show a before/after.

catch’s picture

Status: Needs review » Needs work

This is used quite a lot on dropbutton.css and views ui CSS, so would need to refactor that prior to removal.

Should be possible to do that via https://developer.mozilla.org/en-US/docs/Web/CSS/Reference/At-rules/@med...