dotnet / dotnet/dotnet-api-docs

Note status of regexes for EmailAddressAttribute, PhoneAttribute, UrlAttribute

Offen
#1,201 0 Kommentare 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen
area-System.ComponentModel.DataAnnotations doc-update help wanted Pri2 Pri3
Vorherrschende Sprache
C#
Sterne
949
Forks
1.7k
Ø Merge
2 T. 19 Std.
Gemergte PRs (30 T.)
52

Beschreibung

## Note status of regexes for EmailAddressAttribute, PhoneAttribute, UrlAttribute

See dotnet/dotnet-api-docs#686

In .NET Framework to version 4.6, the [EmailAddressAttribute](https://docs.microsoft.com/dotnet/api/system.componentmodel.dataannotations.emailaddressattribute), [PhoneAttribute](https://docs.microsoft.com/dotnet/api/system.componentmodel.dataannotations.phoneattribute), and [UrlAttribute](https://docs.microsoft.com/dotnet/api/system.componentmodel.dataannotations.urlattribute) relied on regexes for validation. Version 4.6.1 made it possible to disable regex validation, which was on by default. Version 4.7.2 disabled regex validation by default.

.NET Core does not support regex validation for these types.

This needs to be made explicit in the documentation for the three types. For more information, see ["dataAnnotations:dataTypeAttribute:disableRegex" app setting is on by default in .NET Framework 4.7.2](https://docs.microsoft.com/en-us/dotnet/framework/migration-guide/runtime/4.0-4.7.2#web-applications).

//cc @KyleMit

Beitragsleitfaden

Beitragsleitfaden öffnen

Rechercherichtung

Beginne mit den Dokumentationsseiten für EmailAddressAttribute, PhoneAttribute und UrlAttribute und vergleiche anschließend die verlinkten Migrationshinweise für .NET Framework. Beschreibe in der Dokumentation ausdrücklich das Verhalten der Regex-Validierung in .NET Framework und die fehlende Unterstützung dafür in .NET Core für alle drei Typen.

Vom Indexierungsmodell aus dem Issue-Text verfasst.

Bewertung

Tech-Stack
csharp
Bereich
documentation
Issue-Typ
Dokumentation
Schwierigkeit
2/5
Geschätzter Aufwand
Ein halber Tag
Aktivitätsstatus
Veraltet
Klarheit
Größtenteils klar
Anfängerfreundlichkeit
45/100

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.