key static method

Order elements by their key before filtering them.

When using the orderBy="$key" parameter to sort your data, data will be returned in ascending order by key as follows. Keep in mind that keys can only be strings.

  1. Children with a key that can be parsed as a 32-bit integer come first, sorted in ascending order.
  2. Children with a string value as their key come next, sorted lexicographically in ascending order.

Implementation

static FilterBuilder<String> key() => FilterBuilder<String>._(r'$key');