Skip to content

Autocomplete off is being ignored within Microsoft Edge #62296

@MarvinKlein1508

Description

@MarvinKlein1508

Is there an existing issue for this?

  • I have searched the existing issues

Describe the bug

The property autocomplete="off" seems to be ignored by Blazor. Both in InputX components and in normal input binding.

Expected Behavior

I expect the browser to not suggest any details when autocomplete="off" is set.

Steps To Reproduce

  1. Add this razor code:
<EditForm Model="Input" autocomplete="off" id="my-form" name="my-form-name">
    <label for="name">Name:</label>
    <InputText @bind-Value="@Input.DisplayName" autocomplete="off" id="name" name="my-name" />
</EditForm>

<label for="name2">Name:</label>
<input @bind="Input2.DisplayName" autocomplete="off" name="my-name2" id="name2" />

@code {
    public User Input { get; set; } = new();
    public User Input2 { get; set; } = new();

    public class User
    {
        public int UserId { get; set; }
        public string DisplayName { get; set; } = string.Empty;
    }
}
  1. Add personal details in edge like this:

Image

  1. Run the project in Microsoft Edge
  2. Click the inputs

You will see Edge suggestion autocomplete:

Image

Exceptions (if any)

No response

.NET Version

10.0.100-preview.4.25258.110

Anything else?

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