preact-render-to-string
preact-render-to-string copied to clipboard
srcSet not converted to srcset
This works correctly in preact proper
Good catch! Open to a PR, or I can do it whenever I get a chance. I'd like to add an ATTR_MAP mapping like:
const ATTR_MAP = {
'srcSet': 'srcset'
};
Perhaps the keys on the left could be lowercase and we'd compare the lowercase'd JSX attribute names.
Can't we do toLowerCase on everything that's passed onto DOM nodes?
nah, SVG attributes are case-sensitive (viewBox). Though maybe it's easier to special-case that instead.