1
2{ lib, config, ... }:
3let
4 inherit (lib) types;
5in {
6 options = {
7 fun = lib.mkOption {
8 type = types.functionTo (types.listOf types.str);
9 };
10
11 result = lib.mkOption {
12 type = types.str;
13 default = toString (config.fun {
14 a = "a";
15 b = "b";
16 c = "c";
17 });
18 };
19 };
20
21 config.fun = lib.mkMerge [
22 (input: lib.mkAfter [ input.a ])
23 (input: [ input.b ])
24 ];
25}