export function toKebabCase ( input ) { return input . replace ( /[A-Z]/g , ( val , index ) => ( index === 0 ? '' : '-' ) + val . toLowerCase ( ) ) ; } export function removeVersion ( str ) { return str . replace ( /`(\w|\.)+`/g , '' ) . trim ( ) ; } export function formatType ( type ) { return type . replace ( /(^(\*|_))|((\*|_)$)/g , '' ) ; } export function normalizePath ( path ) { return path . replace ( /\\/g , '/' ) ; } export function formatOptions ( options ? ) { if ( ! options ) return [ ] ; return options . replace ( /`/g , '' ) . split ( ' ' ) ; }