LesterLyu / fast-formula-parser

Parse and evaluate MS Excel formula in javascript.
https://www.npmjs.com/package/fast-formula-parser
MIT License
462 stars 64 forks source link

Should isBlank return true for null or undefined value #22

Closed rmdort closed 4 years ago

rmdort commented 4 years ago

Should this be extended to null and undefined values. I think thats how excel or google sheets does the check

value === null || value === void 0 || value === ''

ISBLANK: (value) => {
  if (!value.ref)
      return false;
  value = H.accept(value);
  return typeof value === 'string' && value.length === 0;
}
LesterLyu commented 4 years ago

I'll take a look later.

LesterLyu commented 4 years ago

Released https://github.com/LesterLyu/fast-formula-parser/releases/tag/1.0.18