Browse Source

fix: startDrag params type incorrect (#31084)

Co-authored-by: Black-Hole1 <[email protected]>
trop[bot] 3 years ago
parent
commit
2f543c3fd4
1 changed files with 2 additions and 1 deletions
  1. 2 1
      docs/api/web-contents.md

+ 2 - 1
docs/api/web-contents.md

@@ -1827,7 +1827,8 @@ End subscribing for frame presentation events.
 #### `contents.startDrag(item)`
 
 * `item` Object
-  * `file` String[] | String - The path(s) to the file(s) being dragged.
+  * `file` String - The path to the file being dragged.
+  * `files` String[] (optional) - The paths to the files being dragged. (`files` will override `file` field)
   * `icon` [NativeImage](native-image.md) | String - The image must be
     non-empty on macOS.