Skip to content

A jQuery plugin that helps you visually indicate an element, and generate a jQuery selector to find that element later.

Notifications You must be signed in to change notification settings

conductrics/dom-selector

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

DOM Selector

Use jQuery:

<script type="text/javascript" src="http://code.jquery.com/jquery-1.9.1.min.js"></script>
<script type="text/javascript"> window.jQuery = $.noConflict(); </script>

Include the script on your page:

<script type="text/javascript" src="../dom-selector.js"></script>

When you are ready to select an element:

<script type="text/javascript">
  jQuery.selectElement(function( element, selector ) {
    /* element is the DOM node chosen,
       selector is a string, a jQuery-style selector
    */
  })
</script>

While you are selecting an element, the arrow keys allow you to move around within the DOM:

  • Left - select the parent Node
  • Right - select the first child Node
  • Up / Down - scroll across children

About

A jQuery plugin that helps you visually indicate an element, and generate a jQuery selector to find that element later.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published