New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

vanilla-js

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

vanilla-js

jQuery-like Aliases (NOT Wrappers) to HTML5 Selector API / Raw Document

0.0.1
latest
Source
npm
Version published
Weekly downloads
13
-23.53%
Maintainers
1
Weekly downloads
 
Created
Source

Vanilla JS - fast, lightweight, cross-platform framework

jQuery-like Aliases (NOT Wrappers) to HTML5 Selector API / Raw Document

  • Cross-browser compatible*
    • *HTML5 Selector API is IE8+
    • *XMLHttpRequest is IE7+
    • *Element.prototype is IE8+
  • Forget chaining; its too expensive

Inspired by the classic parody vanilla-js.com.

Demonstration

# btw its XHR, not AJAX
# in Node.js callback style
$.xhr 'GET', 'http://coffeescript.org/robots.txt', '', (err, data, status, xhr) ->
  return console.log err, data, status, xhr, xhr.readyState, xhr.status if err
  console.log status
  console.log data

p = $.liveTag('p')
pp = $.all('p')
console.log p.length
console.log pp.length
#console.log $.one('body').append($.create('p'))
console.log $.create('p').appendTo($.one('body'))
console.log p.length # will be +1
console.log pp.length # will be same as before

View Source

Commented code is in ./coffee/

Helpful

Keywords

Vanilla

FAQs

Package last updated on 24 Jan 2013

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts