We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 22cc5f1 commit d7a0a4dCopy full SHA for d7a0a4d
src/standalone.tsx
@@ -32,7 +32,8 @@ function parseOptionsFromElement(element: Element) {
32
const res = {};
33
for (const attrName in attrMap) {
34
const optionName = attrName.replace(/-(.)/g, (_, $1) => $1.toUpperCase());
35
- res[optionName] = attrMap[attrName];
+ const optionValue = attrMap[attrName];
36
+ res[optionName] = attrName === 'theme' ? JSON.parse(optionValue) : optionValue;
37
// TODO: normalize options
38
}
39
return res;
0 commit comments