1
0
mirror of https://github.com/nushell/nushell.git synced 2025-01-31 02:32:55 +01:00
nushell/docs/commands/empty.md
Justin Ma c0a1d18e3d
update , regenerate commands' docs and update make_docs script ()
* feat: update , regenerate commands' docs

* chore: update make_docs script
2022-02-21 11:26:00 -06:00

588 B

title layout version
empty? command 0.59.0

Check for empty values.

Signature

> empty? ...rest --block

Parameters

  • ...rest: the names of the columns to check emptiness
  • --block {block}: an optional block to replace if empty

Examples

Check if a value is empty

> '' | empty?

more than one column

> [[meal size]; [arepa small] [taco '']] | empty? meal size

use a block if setting the empty cell contents is wanted

> [[2020/04/16 2020/07/10 2020/11/16]; ['' [27] [37]]] | empty? 2020/04/16 -b { |_| [33 37] }