min-dom
TypeScript icon, indicating that this package has built-in type declarations

5.0.0 • Public • Published

min-dom

CI

A minimal dom utility toolbelt. Library friendly and based on utilities provided by component.

Footprint

This library is tiny (2Kb in size) and still exposes all fundamental utilities:

$ npm run bundle
$ gzip dist/index.js
$ du -b dist/*.gz
2351    index.js.gz

Features

The library exposes the following tiny dom helpers:

  • assignStyle - add inline styles to a node
  • attr - get and set node attributes
  • classes - class name helper
  • clear - remove children from a node
  • closest - get the closest parent by selector;
  • delegate - event deletation support; delegate-events
  • domify - html to elements; domify
  • event - event binding; component-event
  • matches - selector match check
  • query - native selector query support
  • remove - detach a node from its parent

Related

  • min-dash - minimal lodash inspired utility toolbelt
  • tiny-svg - tiny SVG utility toolbelt

License

MIT

Package Sidebar

Install

npm i min-dom

Weekly Downloads

94,018

Version

5.0.0

License

MIT

Unpacked Size

30.9 kB

Total Files

7

Last publish

Collaborators

  • vsgoulart
  • skaiir-camunda
  • marstamm
  • bpmn-io-admin
  • nikku
  • barmac
  • philippfromme
  • maxtru