Closed henon closed 3 weeks ago
All modified and coverable lines are covered by tests :white_check_mark:
Project coverage is 90.10%. Comparing base (
28bc599
) to head (51da8f6
). Report is 103 commits behind head on dev.
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
All errors fixed. Ready to merge
I think we probably should not remove this detector, ever.
Not sure about having it permanent as the reflection hurts performance
Also posting code in case we want to lower amount of ifs.
Not sure about having it permanent as the reflection hurts performance
With active opt-in the cost would be a single if
wouldn't this perform a linear search?
// Additional illegal parameters not mapped to specific types
var additionalIllegalParameters = new[]
{
"UnCheckedColor", "Command", "CommandParameter", "IsEnabled", "ClassAction", "InputIcon", "InputVariant",
"AllowKeyboardInput", "ClassActions", "DisableRipple", "DisableGutters", "DisablePadding", "DisableElevation",
"DisableUnderLine", "DisableRowsPerPage", "Link", "Delayed", "AlertTextPosition", "ShowDelimiters",
"DelimitersColor", "DrawerWidth", "DrawerHeightTop", "DrawerHeightBottom", "AppbarMinHeight", "ClassBackground",
"Cancelled", "ClassContent", "IsExpanded", "IsExpandedChanged", "IsInitiallyExpanded", "InitiallyExpanded",
"RightAlignSmall", "IsExpandable"
};
if (additionalIllegalParameters.Contains(parameter))
{
NotifyIllegalParameter(parameter);
}
With active opt-in the cost would be a single if
oh, right
Description
Follow-up to Illegal Razor Parameter Runtime Detection for v7 #8771
I noticed that the detection didn't work for generic types. After fixing that the detector finds at least 26 more illegal usages in our docs and tests. Naturally this PR fails until I fix the old params.
I think we probably should not remove this detector, ever. It is just too useful. We can use it to detect illegal usage of obsolete API in our docs and tests when we enter the next stable development phase. Of course then we'd change it to opt-in instead of opt-out.
How Has This Been Tested?
unit
Type of Changes
Checklist
dev
).