Skip to content

Blank Values

RevoGrid filtering preserves the source value and own-property presence. It does not implicitly turn null, undefined, false, 0, arrays, or missing properties into an empty display string before evaluating filters.

Source stateBlank by default
nullYes
Owned undefinedYes
Exactly ""Yes
Missing own propertyYes
Whitespace-only stringNo
falseNo
0No
NaNNo
[]No
Non-empty arrayNo
Object or other valueNo

Only an own property counts as present. A value inherited through the row prototype is treated as missing. null and undefined can both match Is blank while remaining distinct raw values.

The stable saved-state IDs remain empty and notEmpty; no state migration is required. Their default labels are Is blank and Is not blank, and Is not blank is the exact inverse of the resolved blank predicate.

Set the grid policy in the filter configuration. A column can override any individual field; resolution is Core defaults, then grid policy, then column policy.

grid.filter = {
blankSemantics: {
whitespaceOnlyString: true,
emptyArray: true,
isBlank(value, context, fallbackResult) {
// Final application override after the configured fallback.
return value === 'N/A' || fallbackResult;
},
},
};
grid.columns = [{
prop: 'tags',
filter: ['array'],
blankSemantics: {
// Other fields continue to inherit from the grid policy.
emptyArray: false,
},
}];

The callback receives the raw source value, row model, column, property, parsed value, own-property status, effective policy, and fallback result.

A cellParser still supplies the value used by ordinary comparisons. Blank evaluation uses the source value and missing-property context captured before the parser runs.

Typed operators remain strict. isTrue matches only true; isFalse matches only false; isEmptyArray and isNotEmptyArray match only arrays. Enabling emptyArray: true intentionally allows [] to match both Is blank and Is empty array. Invalid nonblank date values, including false and NaN, do not match date comparisons and are not blank by default.