feat: Radio改造
This commit is contained in:
@@ -36,6 +36,13 @@ export const underlineToHump = (str: string): string => {
|
||||
})
|
||||
}
|
||||
|
||||
/**
|
||||
* 驼峰转横杠
|
||||
*/
|
||||
export const humpToDash = (str: string): string => {
|
||||
return str.replace(/([A-Z])/g, '-$1').toLowerCase()
|
||||
}
|
||||
|
||||
export const setCssVar = (prop: string, val: any, dom = document.documentElement) => {
|
||||
dom.style.setProperty(prop, val)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user