Skip to content

Latest commit

 

History

History
23 lines (17 loc) · 821 Bytes

styleString2Object.md

File metadata and controls

23 lines (17 loc) · 821 Bytes

styleString2Object

Transform a style string to an object representation

Parameters

Name Type Description Status Default
style { String } The style string required

Return { (Object) } The string object representation

Example

	import styleString2Object from 'coffeekraken-sugar/js/dom/styleString2Object'
const styleString = styleString2Object('padding-left:20px; display:block;');
// output => {
//		paddingLeft : '20px',
// 		display : 'block'
// }

Author : Olivier Bossel [email protected] https://olivierbossel.com