Skip to content

Simple query plugin to set/get element state via data attributes (data-state).

Notifications You must be signed in to change notification settings

blimpllc/jquery.state

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 

Repository files navigation

jquery.sate

Simple query plugin to set/get element state via data attributes (data-state).

Get current state

$('element').state(); // returns string or null

Returns the current state of the element or null if the element has no data-state attribute.

Set current state

// <element data-state="selected"></element>

$('element').state('selected');

Sets a data-state attribute with the state specified.

About

Simple query plugin to set/get element state via data attributes (data-state).

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published