3.0.0 • Published 3 years ago

mishamyrt-noquery v3.0.0

Weekly downloads
2
License
MIT
Repository
github
Last release
3 years ago

noQuery Quality assurance

A function for elements selection in 71 ASCII chars.

import { $ } from 'mishamyrt-noquery'

const title = $('h1')

If only one element is found, the function will return it. Otherwise, it will return an array with all native methods.

const handleClick = () => alert('Whoops')
const isRed = n => n.classList.contains('__red')

// Set click callback to all red buttons
$('.button')
  .filter(isRed)
  .forEach(n => n.addEventListener('click', handleClick))
3.0.0

3 years ago

2.0.0

4 years ago

1.0.3

5 years ago

1.0.2

5 years ago

1.0.1

5 years ago

1.0.0

5 years ago