Skip to content

Consider supporting Label in addition to DisplayName #64791

@ilonatommy

Description

@ilonatommy

Is there an existing issue for this?

  • I have searched the existing issues

Is your feature request related to a problem? Please describe the problem.

#64636 added DisplayName that can be used like:

        <label class="form-label">
            <DisplayName For="@(() => product.Name)" />
        </label>

Following up on the comment we should consider if we want to add support for label.

cc @danroth27

Describe the solution you'd like

  <label for="input-name">Label text</label>
  <input name="input-name" />
<label>
Label text
<input name="input-name" />
</label>

Additional context

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    area-blazorIncludes: Blazor, Razor Components

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions