Skip to documentation
SplitScript
  • Language
  • Standard library
  • Guides
  • Migration

SplitScript reference / Map<K, V> / isEmpty

Map<K, V>.isEmpty

Method

Map<K, V>.isEmpty() -> bool where K: Equatable

Reports whether this map contains no entries.

A newly created or cleared map is empty.

Effects: pure

Runtime behavior: available everywhere; synchronous

Examples

Check a new map

let routes = Map.new<String, u32>()
let empty = routes.isEmpty()
Generated from the SplitScript compiler's documentation catalogs.