Git Product home page Git Product logo

qwery's Introduction

Qwery

Qwery is a modern selector engine built on top of querySelectorAll giving you practical utility.

Deprecation Notice!

As of version 4.0, qwery no longer supports IE6 - IE8. If your application still requires this level of support, please see the final 3.x release.

Browser Support

  • IE9+
  • Chrome 1+
  • Safari 3+
  • Firefox 4+

Contexts

Each query can optionally pass in a context

qwery('div', node); // existing DOM node or...
qwery('div', '#foo'); // another query

Dev Env & Testing

npm install
make test

Ender support

Qwery is the recommended selector engine for Ender. If you don't have Ender, install it, and don't ever look back.

npm install ender -g

Include qwery into your package.json

{
  "dependencies": {
    "qwery": "x.x.x"
  }
}

Ender bridge additions

// the context finder - find all p elements descended from a div element
$('div').find('p')

// join one set with another
$('div').and('p') // equal to $('div,p')

Recommended sibling modules

In most cases, if you're hunting for a selector engine, you probably want to pair Qwery with a DOM module. In that case qwery pairs quite nicely with Bonzo (a DOM util) and Bean (an event util). Add them to your Ender installation as such:

ender build qwery bean bonzo

Then write code like a boss:

$('<p>hello world</p>')
  .css({
    color: 'red',
    background: 'white'
  })
  .after('โˆš')
  .bind({
    'click.button': function () {
      $(this).hide().unbind('click.button')
    }
  })
  .appendTo('body')

Giving back

Are you using this library in production? Consider leaving a tip to show your appreciation.

qwery's People

Contributors

amccollum avatar benvinegar avatar bowsersenior avatar clintandrewhall avatar cvrebert avatar ded avatar dustinsenos avatar fat avatar jamischarles avatar jdalton avatar olleolleolle avatar remi avatar runningskull avatar rvagg avatar rwaldin avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.