engine
engine copied to clipboard
Input preprocessors
If we have following schema:
export class Foo {
@validation.assertPattern(/^#[0-9a-fA-F]{6}$/, 'Invalid color.')
color = d.stringColumn().notNull()
}
We accept both #0094FF
and #0094ff
although they represent the same color. It would be nice, to allow both lowercase and uppercase variants to be submitted, but before storing them in database to normalize them (eg. lowercasing them).