Accordions
These accordions have been created using javaScript, jQuery, HTML and CSS. The neccessary code is shared below.
The accordion is created with a button using class accordion.
When to Use
Accordions help with cognitive load on pages where there is a lot of content that for some reason cannot be separated onto multiple pages.
With accordions the user in charge of showing the content, and can choose only the content they are interested in.
Accordions should only be used when a minimum of three will be needed. Expand and collapse buttons should always be used.
Example
Code
The code sample below allows you to quickly implement accordions into your prototype.
Last Modified: June 2, 2025