prependKeysWith<V> static method

Map<String, V> prependKeysWith<V>(
  1. Map<String, V> map,
  2. String prefix
)

Prefixes every top-level key in map with prefix.

Implementation

static Map<String, V> prependKeysWith<V>(Map<String, V> map, String prefix) =>
    {for (final e in map.entries) '$prefix${e.key}': e.value};