Remix.run Logo
dspillett 4 days ago

I try to keep to that, but sometimes the flag is turning on a negative feature, disabling that which is the default and will remain so for compatibility reasons.

Sometimes it is worth the effort of going through and changing the logic elsewhere to keep the boolean positive, sometimes that would be too much effort to retest at the time.

Another option I like, when I have a config object interpreting things so I'm reading doing `if (config.IsWhateverThatThingIsEnabled)` then I can just have paired properties to pick from when I want to check IsEnabled or IsDisabled.

I've come across code where there is an overide for an option to disable something and the naming plus the logical not really make you think about what is happening…

    if (!OverrideDisabledOptionToBlockAction) {}