Express CSV Logo

Time

Use x.time() for time values (no date component).

x.time().label("Shift Start")

columnNameAliases

Use alternate CSV headers for the same field.

.columnNameAliases(aliases: string[])

  • aliases lists the alternate column names.

label

Sets the user-facing label shown in the widget.

.label(text: string)

  • text sets the label text.

description

Sets help text shown below the field.

.description(text: string)

  • text sets the description text.

example

Sets the placeholder example value.

.example(text: string)

  • text sets the example value.

optional

Makes the field optional.

.optional()

default

Available after .optional().

.default(defaultValue: unknown | (() => unknown | Promise<unknown>))

  • defaultValue can be a static value or a function used when the field is empty.

precision

Sets the number of fractional-second digits.

.precision(precision: number, options?: { message?: string })

  • precision sets the precision from 0 to 9, e.g., 3.
  • message overrides the validation error text, e.g., "Time must include milliseconds".

On this page