lightAccordion
A lightweight accordion for your AngularJS App

Usage


lightAccordion: adding the module to you're app
  1. Import JS in your page
  2. Import CSS in your page
  3. Import the "lightAccordion" module in your app:
    
                                    var app = angular.module("myApp", ["lightAccordion"]);
                                    
                                    
  4. Use the "light-accordion" element where you want your accordion to be:
    
                                <light-accordion>
                                <!-- YOUR CONTENT -->
                                <any>
                                <!-- OTHER CONTENT -->
                                </any>
                                <any >
                                <!-- OTHER CONTENT AGAIN -->
                                </any>
                                </light-accordion>
                            

Options


(Put this options as attributes on the element with the "light-accordion" attribute)


Option Description Type Default value
heading Text for the header of your accordion String ""
is-open A value from your controller ("=?") to control if the accordion is opened Boolean ""

Demo


MY ACCORDION CONTENT

Lorem ipsum dolor sit amet consectetur...

MY ACCORDION CONTENT

Lorem ipsum dolor sit amet consectetur...

About


lightAccordion is an angular directive to easily create accordions in your website!