UNPKG

@buka/class-transformer-extra

Version:

class-transformer-extra contains methods that's aren't included in the class-transform package.

7 lines (6 loc) 243 B
import { Transform } from 'class-transformer'; export function ToUpperCase(options) { return Transform(function ToUpperCaseTransform({ value }) { return (typeof value === 'string' ? value.toUpperCase() : value); }, options); }