import { ICaseStyleConverter } from "./CaseStyleConverter" ; /**
 * Converts a series of words to dash-lower-case.
 */ export class DashLowerCaseConverter implements ICaseStyleConverter { param words returns public convert ( words ) { if ( words . length === 0 ) { return "" ; } let result = "" ; for ( let i = 0 ; i < words . length - 1 ; i += 1 ) { const word = words [ i ] ; result += word . toLowerCase ( ) + "-" ; } result += words [ words . length - 1 ] . toLowerCase ( ) ; return result ; } }