GoScrobble/web/node_modules/dom-helpers/esm/hyphenate.js

4 lines
124 B
JavaScript
Raw Permalink Normal View History

2022-04-25 02:47:15 +00:00
var rUpper = /([A-Z])/g;
export default function hyphenate(string) {
return string.replace(rUpper, '-$1').toLowerCase();
}