export function capitalize(str: string, all: boolean = false) { if (all) return str.split(' ').map(s => capitalize(s)).join(' '); return str.charAt(0).toUpperCase() + str.slice(1); }