import { OptionMetadata , OptionType , kebabCase } from "@miniflare/shared" ; export function argName ( key , { name , type } ) { name ??= kebabCase ( key ) ; if ( ( type === OptionType . ARRAY || type === OptionType . OBJECT ) && name . endsWith ( "s" ) ) { name = name . substring ( 0 , name . length - 1 ) ; } return name ; }