style-attr

Very simple parsing and stringifying of style attributes.

License

MIT

style-attr

Very simple parsing and stringifying of style attributes.

parse

Convert a style attribute string to an object.

stringify

Convert an object into an attribute string

normalize

Normalize an attribute string (eg. collapse duplicates)

Tests

Can be run with npm run test

tests for style-attr→parse

tests for style-attr→stringify

tests for style-attr→normalize