Replies: 1 comment
-
I agree. This seems too seldomly useful and too confusing to new users.
I am not vehemently opposed, but I don't see a use case for this. If we do add this, we will want to document it well, but also make sure that it doesn't become more static in the documentation for the average user to filter out. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Here are two proposals for introducing
options.stylix.targets.${name}.config
andoptions.stylix.targets.${name}.extraConfig
options tomkTarget
. Note that the option names are subject to change.IMHO, I am against the
options.stylix.targets.${name}.config
option due to imposed complexity on end-users:The
options.stylix.targets.${name}.config
proposal is mostly only included in this discussion for reference.The
options.stylix.targets.${name}.extraConfig
option seems like an uncontroversial addition, since it allows extending the Stylix default declarations under thestylix
namespace, while leveragingmkTarget
's automatic safeguarding.options.stylix.targets.${name}.config
This would generally solve the inconsistency of using the Stylix default declarations as a foundation.
This also enables a complementary use case to overriding individual declarations with
lib.mkForce
, where the entire target can be disabled usingstylix.targets."<TARGET>".enable = false;
and only desired sections are included. When only a small portion of declarations is undesired,lib.mkForce
is the most convenient. When the majority is undesired, disabling the target and reusing only selected parts is more effective.Considering
mkTarget
's automatic safeguarding, this may lead to end-users partially re-implementing this safeguarding. To avoid encouraging complexity on end-users, I suggest abandoning this generaloptions.stylix.targets.${name}.config
option.options.stylix.targets.${name}.extraConfig
Unlike the previous
options.stylix.targets.${name}.config
proposal, this would simply extend the Stylix declarations.Context
For reference, here is some additional context:
CC: @awwpotato, @danth, @Flameopathic
Beta Was this translation helpful? Give feedback.
All reactions