philbuchanan / Accordion-Shortcodes

A WordPress plugin that adds a few shortcodes to allow for accordion dropdowns.
https://wordpress.org/plugins/accordion-shortcodes/
16 stars 10 forks source link

Hide all content by default with display: none #75

Open philbuchanan opened 5 years ago

philbuchanan commented 5 years ago

This will remove the flash of seeing all accordion item's content when the page is loading. Then swap the plugin to openItem() instead of closeItem() on load.

Use the no-js CSS class to force them open in CSS:

.no-js .c-accordion__content {
    display: block !important;
}