Browse Source

docs: fix a syntax issue in document breaking changes (#44904)

fix: syntax issue in docs

Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: illusory-dream <[email protected]>
trop[bot] 4 months ago
parent
commit
e76893eaed
1 changed files with 2 additions and 2 deletions
  1. 2 2
      docs/breaking-changes.md

+ 2 - 2
docs/breaking-changes.md

@@ -107,14 +107,14 @@ The nonstandard `path` property of the Web `File` object was added in an early v
 ```js
 // Before (renderer)
 
-const file = document.querySelector('input[type=file]')
+const file = document.querySelector('input[type=file]').files[0]
 alert(`Uploaded file path was: ${file.path}`)
 ```
 
 ```js
 // After (renderer)
 
-const file = document.querySelector('input[type=file]')
+const file = document.querySelector('input[type=file]').files[0]
 electron.showFilePath(file)
 
 // (preload)