Unverified Commit 67d326a5 authored by Rhon Joe's avatar Rhon Joe Committed by GitHub

fix(web): fix svg unrecognized props (#631)

parent fe747040
...@@ -15,6 +15,7 @@ export type Attrs = { ...@@ -15,6 +15,7 @@ export type Attrs = {
export function normalizeAttrs(attrs: Attrs = {}): Attrs { export function normalizeAttrs(attrs: Attrs = {}): Attrs {
return Object.keys(attrs).reduce((acc: Attrs, key) => { return Object.keys(attrs).reduce((acc: Attrs, key) => {
const val = attrs[key] const val = attrs[key]
key = key.replace(/([-]\w)/g, (g: string) => g[1].toUpperCase())
switch (key) { switch (key) {
case 'class': case 'class':
acc.className = val acc.className = val
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment