Skip to content

stoeffel/css-longhand

 
 

Repository files navigation

css-longhand Build Status

Expand CSS shorthands.

Why?

For HTML E-maliers.

Install

$ npm install --save css-longhand

Supported CSS properties:

  • margin

  • padding

  • border

Usage

var cssLonghand = require('css-longhand');
cssLonghand('/path/to/css');

Example:

.classname {
	margin: 0;
}

Pass to cssLonghand will result in:

.classname {
		margin-top: 0;
		margin-right: 0;
		margin-bottom: 0;
		margin-left: 0;
}

TODO:

  • Re-implement with streams (find the comment in the code)

  • Support more CSS properties.

License

MIT © hemanth.hm

About

Expand shorthand CSS.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • JavaScript 87.6%
  • CSS 12.4%