query
On this page

mapAttrsFlatten

lib.mapAttrsFlatten

Docs pulled from | This Revision | 21 minutes ago


Call a function for each attribute in the given set and return the result in a list.

Inputs

f

A function, given an attribute's name and value, returns a new value.

attrs

Attribute set to map over.

Type

mapAttrsToList :: (String -> a -> b) -> AttrSet -> [b]

Examples

lib.attrsets.mapAttrsToList usage example

mapAttrsToList (name: value: name + value)
   { x = "a"; y = "b"; }
=> [ "xa" "yb" ]
(lib.attrsets.mapAttrsToList)

Noogle also knows

Aliases