Important: This documentation covers Yarn 1 (Classic).
For Yarn 2+ docs and migration guide, see yarnpkg.com.

Package detail

component-css

component522MIT0.0.8

DOM element css helper

readme

css

jQuery's css() method.

Installation

Install with component(1):

$ component install component/css

API

css(el, prop)

Get the computed value of the prop on el.

css(p, 'color')

css(el, prop, value)

Set the CSS value on the prop on el

css(p, 'color', 'red')

css(el, styles)

Set a styles object to el

css(p, {
  color: 'red',
  background: 'blue'
})

TODO

License

MIT

changelog

0.0.8 / 2016-04-01

  • fix: properly fix component-each require (#18, @ockham)

0.0.7 / 2016-03-15

  • package: don't use browser alias for component-each dependency (#17, @ockham)

0.0.6 / 2014-05-27

  • gitignore: ignore node_modules (#12, @jonnsl)
  • package: add dependencies, devdependencies and browser for browserify support

0.0.5 / 2014-04-22

  • package: don't pin debug version
  • prop, css: fix debug() call arguments
  • Feature checking on document.documentElement instead of document.body

0.0.4 / 2014-01-22

  • IE8 support (@dominicbarnes)

0.0.3 / 2014-01-03

  • added phantom testing
  • replace component/css a port of jquery's .css()

0.0.2 / 2013-01-26

  • add css number blacklist