Skip to content

[ABANDONED] Simple toggling library for HTML, based on data attributes

License

Notifications You must be signed in to change notification settings

Carrooi/Node-HtmlToggle

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

NPM version Dependency Status Build Status

Donate

html-toggle

Simple toggling library for HTML, based on data attributes.

Uses jquery.

Help

Unfortunately I don't have any more time to maintain this repository :-(

Don't you want to save me and this project by taking over it?

sad cat

Installation

install for commonJS environments (for example simq):

$ npm install html-toggle

or download standalone version:

Usage

<script type="text/javascript">
	$(function() {
		// var Toggle = require('html-toggle');		// only for commonJS

    	Toggle(jQuery);
	});
</script>

<a href="#" data-toggle data-toggle=".languages">Show or hide all languages</a>

<ul class="languages">
	...
</ul>

Hide link after first toggle

data-hide-toggler

<a href="#" data-toggle data-hide-toggler data-toggle=".languages">Show all languages</a>

Specifying fire event

data-event

<a href="#" data-toggle data-event="mouseover" data-toggle=".languages">Show all languages</a>

Tests

$ npm test

Changelog

  • 1.0.1

    • Move under Carrooi organization
    • Abandon package
  • 1.0.0

    • Initial version

About

[ABANDONED] Simple toggling library for HTML, based on data attributes

Resources

License

Stars

Watchers

Forks

Packages

No packages published