dotnet / dotnet/dotnet-api-docs

MinLength/MaxLength description is too specific

Open
#10,981 2 comments 0 reactions 0 assignees View on GitHub
area-System.ComponentModel.DataAnnotations untriaged
Dominant language
C#
Stars
949
Forks
1.7k
Avg merge
3d 27m
Merged PRs (30d)
49

Description

### Type of issue

Typo

### Description

The description says that the `MinLengthAttribute` and `MaxLengthAttribute` attributes works on "length of array or string data", while the description of the `LengthAttribute` attribute says it works on "length of collection/string data".

Looking at the source, all three attributes uses `CountPropertyHelper.TryGetCount()`, so the descriptions should be similar.

Please change the description of `MinLengthAttribute` and `MaxLengthAttribute` to match the wording of `LengthAttribute`, such that it mentions "collection" instead of "array".

### Page URL

https://learn.microsoft.com/en-us/dotnet/api/system.componentmodel.dataannotations.minlengthattribute?view=net-9.0

### Content source URL

https://github.com/dotnet/dotnet-api-docs/blob/main/xml/System.ComponentModel.DataAnnotations/MinLengthAttribute.xml

### Document Version Independent Id

cea3e844-0415-4269-9f5a-ec4b71c3ff21

### Article author

@dotnet-bot

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.