2017 © Pedro Peláez
 

wordpress-plugin genesis-js-no-js

WordPress plugin for Genesis child themes to allow differing styles for elements if JavaScript is active or not.

image

gamajo/genesis-js-no-js

WordPress plugin for Genesis child themes to allow differing styles for elements if JavaScript is active or not.

  • Tuesday, March 13, 2018
  • by GaryJones
  • Repository
  • 3 Watchers
  • 17 Stars
  • 76 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 2 Forks
  • 2 Open issues
  • 7 Versions
  • 49 % Grown

The README.md

Genesis JS / No JS

Make front end styling easier for child themes on the Genesis Framework based on whether JavaScript is enabled or not., (*1)

Description

If you look at the source of a WordPress back end page, you'll see it has a body class of no-js. Immediately after the opening body tag is a small script which replaces no-js with js (you can see the amended class with Firebug / Inspector)., (*2)

WordPress uses this to apply different styles to the same elements, depending on whether JavaScript is present or not., (*3)

This plugin recreates the same effect, but for the front end of Genesis Framework child themes. It uses the genesis_before hook supplied by Genesis, so it won't work for other themes., (*4)

The script is fairly small so does not block rendering of other content for any noticeable length of time., (*5)

Putting the script at the top also reduces a flash of incorrectly styled content, as the page does not load with no-js styles, then switch to js once everything has finished loading., (*6)

Installation

Once this plugin is installed and activated, then it will work automatically. There are no options, and nothing to set-up., (*7)

Upload

  1. Download the latest tagged archive (choose the "zip" option).
  2. Go to the Plugins -> Add New screen and click the Upload tab.
  3. Upload the zipped archive directly.
  4. Go to the Plugins screen and click Activate.

Manual

  1. Download the latest tagged archive (choose the "zip" option).
  2. Unzip the archive.
  3. Copy the folder to your /wp-content/plugins/ directory.
  4. Go to the Plugins screen and click Activate.

Check out the Codex for more information about installing plugins manually., (*8)

Git

Using git, browse to your /wp-content/plugins/ directory and clone this repository:, (*9)

git clone git@github.com:GaryJones/genesis-js-no-js.git, (*10)

Then go to your Plugins screen and click Activate., (*11)

Composer

composer require gamajo/genesis-js-no-js

Updates

This plugin supports the GitHub Updater plugin, so if you install that, this plugin becomes automatically updateable direct from GitHub., (*12)

Credits

Built by Gary Jones
Copyright 2011 Gamajo, (*13)

The Versions

13/03 2018
29/11 2017

3.1.1

3.1.1.0 https://github.com/GaryJones/genesis-js-no-js

WordPress plugin for Genesis child themes to allow differing styles for elements if JavaScript is active or not.

  Sources   Download

GPL-2.0+

The Requires

 

The Development Requires

javascript genesis genesis-js-no-js

28/11 2017

3.1.0

3.1.0.0 https://github.com/GaryJones/genesis-js-no-js

WordPress plugin for Genesis child themes to allow differing styles for elements if JavaScript is active or not.

  Sources   Download

GPL-2.0+

The Requires

 

The Development Requires

javascript genesis genesis-js-no-js

24/08 2017

3.0.1

3.0.1.0 https://github.com/GaryJones/genesis-js-no-js

WordPress plugin for Genesis child themes to allow differing styles for elements if JavaScript is active or not.

  Sources   Download

GPL-2.0+

The Requires

 

The Development Requires

javascript genesis genesis-js-no-js

24/08 2017

3.0.0

3.0.0.0 https://github.com/GaryJones/genesis-js-no-js

WordPress plugin for Genesis child themes to allow differing styles for elements if JavaScript is active or not.

  Sources   Download

GPL-2.0+

The Requires

 

The Development Requires

javascript genesis genesis-js-no-js