You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
After starting to create an extension for DevToys, I identified several areas that could benefit from improvements.
Settings Group
Unless I missed something, it appears that the IUISettingHandle extension methods only support dropdown and switch controls. In my case, I needed to handle numeric settings, which are not supported out of the box. This scenario can currently be achieved by manually creating the desired control using InteractiveElement(this IUISetting element, IUIElement? uiElement), but this approach is not as integrated as the "Handle way". For example, you need to manage the setting persistence yourself. It would be great to dynamically create more types of setting controls (e.g., switch for SettingDefinition<bool>, numeric for SettingDefinition<int>, etc.).
Unit Tests
While writing my unit tests, I realized that some useful features for testing the default tools shipped with DevToys are not accessible outside the DevToys.Tools package:
Mocks
TestBase class
Other?
Would it be a good idea to move these features from DevToys.Tools.UnitTests to DevToys.Api.UnitTests?
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Hi,
After starting to create an extension for DevToys, I identified several areas that could benefit from improvements.
Settings Group
Unless I missed something, it appears that the
IUISetting
Handle
extension methods only support dropdown and switch controls. In my case, I needed to handle numeric settings, which are not supported out of the box. This scenario can currently be achieved by manually creating the desired control usingInteractiveElement(this IUISetting element, IUIElement? uiElement)
, but this approach is not as integrated as the "Handle
way". For example, you need to manage the setting persistence yourself. It would be great to dynamically create more types of setting controls (e.g., switch forSettingDefinition<bool>
, numeric forSettingDefinition<int>
, etc.).Unit Tests
While writing my unit tests, I realized that some useful features for testing the default tools shipped with DevToys are not accessible outside the DevToys.Tools package:
Would it be a good idea to move these features from DevToys.Tools.UnitTests to DevToys.Api.UnitTests?
Best regards,
Ruben
Beta Was this translation helpful? Give feedback.
All reactions