Add pushState helper
This commit is contained in:
parent
3610987241
commit
22ec74b9d1
2 changed files with 17 additions and 25 deletions
|
|
@ -11,4 +11,8 @@ pkgs: rec {
|
|||
rawOrStr._noescape
|
||||
else
|
||||
pkgs.lib.strings.escapeShellArg rawOrStr;
|
||||
|
||||
pushState =
|
||||
key: toPush: state:
|
||||
state // { ${key} = state.${key} ++ [ toPush ]; };
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue