We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 8571f13 commit 072c61cCopy full SHA for 072c61c
src/index.ts
@@ -2,6 +2,8 @@ import type { Properties } from 'csstype';
2
3
const style = (node: HTMLElement, parameters: Properties<string | number>) => {
4
Object.entries(parameters).forEach(([key, value]) => {
5
+ key = key.replace(/[A-Z]/, (substring) => '-' + substring.toLowerCase());
6
+
7
node.style.setProperty(key, value);
8
});
9
};
0 commit comments