Need private packages and team management tools?Check out npm Teams »

tabable

1.0.0 • Public • Published

Tabable

This is a simple module that will add tab-index attributes to your elements. Build Status

Install

$ npm install tabable

Usage

tabable( element[, filter ] )

Given an element, tabable find all the inputs (or whatever you specify via the optional filter argument) within it an give them a tab-index. Eg:

var tabable = require( 'tabable' );
 
// make all the inputs have a reasonable tab-index
tabable( document.getElementById( 'foo' ) );

Only want textareas to be tabable?

var tabable = require( 'tabable' );
 
// only set tab-index on the textarea elements
tabable( document.getElementById( 'foo' ), 'textarea' );
Have an issue? report it in the issues tab.

Install

npm i tabable

DownloadsWeekly Downloads

7

Version

1.0.0

License

MIT

Last publish

Collaborators

  • avatar