wayfinderSearchInput top-level property

ObjectSchema wayfinderSearchInput
final

The search a host tool accepts, as JSON: a query with a non-blank character and an optional limit from 1 to 100 (default 5). The CLI converts its arguments to numbers before parsing them with it.

Implementation

final wayfinderSearchInput = Ack.object({
  'query': Ack.string()
      .minLength(1)
      .matches(
        _nonBlank,
        message: 'Query must contain non-whitespace characters.',
      ),
  'limit': Ack.integer().min(1).max(100).optional().withDefault(5),
});