jQuery

jQuery: The Write Less, Do More, JavaScript Library (packaged for Node.JS)

This is deprecated. Please use 'jquery' (all lowercase).
Last updated 14 years ago .
MIT · Repository · Bugs · Original npm · Tarball · package.json
$ npm install jQuery 
SYNC missed versions from official npm registry.

node-jQuery

A stupid-simple wrapper over jQuery for Node.JS (server). Currently 1.7.2.

Node.JS

npm install jQuery

var $ = require('jQuery');

Examples

$("<h1>test passes</h1>").appendTo("body");
console.log($("body").html());

In Node.JS you may also create separate window instances

var jsdom = require('jsdom').jsdom
  , myWindow = jsdom().createWindow()
  , $ = require('jQuery')
  , jq = require('jQuery').create()
  , jQuery = require('jQuery').create(myWindow)
  ;

$("<h1>test passes</h1>").appendTo("body");
console.log($("body").html());

jq("<h2>other test passes</h2>").appendTo("body");
console.log(jq("body").html());

jQuery("<h3>third test passes</h3>").appendTo("body");
console.log(jQuery("body").html());

Output:

<h1>test passes</h1>
<h2>other test passes</h2>
<h3>third test passes</h3>

JSONP Example

var $ = require('jQuery');

$.getJSON('http://twitter.com/status/user_timeline/treason.json?count=10&callback=?',function(data) {
  console.log(data);
});

Current Tags

  • 1.7.4                                ...           latest (14 years ago)

5 Versions

  • 1.7.4 [deprecated]           ...           14 years ago
  • 1.7.3 [deprecated]           ...           14 years ago
  • 1.7.2 [deprecated]           ...           15 years ago
  • 1.6.3 [deprecated]           ...           15 years ago
  • 1.6.2 [deprecated]           ...           15 years ago
Maintainers (2)
Downloads
Total 10
Today 0
This Week 0
This Month 5
Last Day 0
Last Week 2
Last Month 5
Dependencies (5)
Dev Dependencies (2)
Dependents (1)

© 2010 - cnpmjs.org x YWFE | Home | YWFE