Skip to content

Commit

Permalink
fix(@angular-devkit/build-angular): don't restore input of type `fi…
Browse files Browse the repository at this point in the history
…le` during HMR

```
Uncaught DOMException: Failed to set the 'value' property on 'HTMLInputElement': This input element accepts a filename, which may only be programmatically set to the empty string.
```

Closes #22084

(cherry picked from commit 47fd128)
  • Loading branch information
alan-agius4 authored and clydin committed Nov 4, 2021
1 parent a0ff636 commit 35164bf
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
Expand Up @@ -58,7 +58,9 @@ describe('Dev Server Builder HMR', () => {
<p>{{title}}</p>
<input class="visible" type="text">
<input type="file">
<input type="hidden">
<select>
<option>one</option>
<option>two</option>
Expand Down
Expand Up @@ -197,7 +197,6 @@ function restoreFormValues(oldInputs: any[], oldOptions: any[]): void {
case 'date':
case 'datetime-local':
case 'email':
case 'file':
case 'hidden':
case 'month':
case 'number':
Expand Down

0 comments on commit 35164bf

Please sign in to comment.