src/compiler.js
function compileProps(props) {
    const transformKey = when(equals('className'), ~'class');
    const transformValue = ifElse(type & equals('Object'),
        compileCSS, unary(JSON.stringify));

    const result = props
        | toPairs
        | map(([key, value]) => `${transformKey(key)}=${transformValue(value)}`)
        | join(' ');

    return result.length === 0 ? '' : ` ${result}`;
}
function compileProps(props) {
    const transformKey = when(equals('className'), ~'class');
    const transformValue = ifElse(type & equals('Object'),
        compileCSS, unary(JSON.stringify));

    const result = props
        | toPairs
        | map(([key, value]) => `${transformKey(key)}=${transformValue(value)}`)
        | join(' ');

    return result.length === 0 ? '' : ` ${result}`;
}
function compileProps ( props ) { const transformKey = when ( equals ( 'className' ) , ~ 'class' ) ; const transformValue = ifElse ( type & equals ( 'Object' ) , compileCSS , unary ( JSON . stringify ) ) ; const result = props | toPairs | map ( ( [ key , value ] ) => ` ${ transformKey ( key ) } ${ transformValue ( value ) } ` ) | join ( ' ' ) ; return result . length === 0 ? '' : ` ${ result } ` ; }
Generates HTML string for element properties

@param {Object} props
@return {String}
Generates HTML string for element properties