/** * Transforms an sql domain name into a value to be used by zapatos as a Custom type name, e.g. some_enum -> SomeEnum */ export const transformCustomType = (domainName: string): string => { const camelCasedName = domainName.replace(/_[^_]/g, (m) => m.charAt(1).toUpperCase(), ); return camelCasedName.charAt(0).toUpperCase() + camelCasedName.slice(1); };