Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

bianco.query

Package Overview
Dependencies
Maintainers
3
Versions
14
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

bianco.query - npm Package Compare versions

Comparing version 1.0.0 to 1.1.0

6

index.js

@@ -10,8 +10,8 @@ 'use strict';

* @param { string|DOMNodeList } selector - either the query or the DOM nodes to arraify
* @param { HTMLElement } ctx - context defining where the query will search for the DOM nodes
* @param { HTMLElement } scope - context defining where the query will search for the DOM nodes
* @returns { Array } DOM nodes found as array
*/
function $(selector, ctx) {
function $(selector, scope) {
return domToArray(typeof selector === 'string' ?
(ctx || document).querySelectorAll(selector) :
(scope || document).querySelectorAll(selector) :
selector

@@ -18,0 +18,0 @@ )

@@ -6,10 +6,10 @@ import domToArray from 'bianco.dom-to-array'

* @param { string|DOMNodeList } selector - either the query or the DOM nodes to arraify
* @param { HTMLElement } ctx - context defining where the query will search for the DOM nodes
* @param { HTMLElement } scope - context defining where the query will search for the DOM nodes
* @returns { Array } DOM nodes found as array
*/
export default function $(selector, ctx) {
export default function $(selector, scope) {
return domToArray(typeof selector === 'string' ?
(ctx || document).querySelectorAll(selector) :
(scope || document).querySelectorAll(selector) :
selector
)
}
{
"name": "bianco.query",
"version": "1.0.0",
"version": "1.1.0",
"description": "Modern DOM query selectors helpers written in es2015",

@@ -8,2 +8,3 @@ "main": "index.js",

"module": "index.next.js",
"types": "index.d.ts",
"scripts": {

@@ -10,0 +11,0 @@ "prepare": "npm run build && npm test",

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc