[Feature] Set File.path property when uploading files with Electron
See original GitHub issueMy application uses the q-file feature of the quasar framework.here is the q-file link. When a file is uploaded, it gets the path parameter of the file in the files object array to find the local address where the file is located.
This is the file object printed in Developer tools after I uploaded the file manually, you can see the properties ‘path’ is not empty
I uploaded the file using setInputFiles() and ‘path’ is empty.
await window.locator('input[type="file"]').setInputFiles(path.resolve(__dirname, '../cypress/fixtures/samples/GoneNutty.avi'))
I know setInputFiles() has only 3parameters,can I still use other methods to achieve passing ‘path’,if you see my problem I hope you can help me,thanks a lot.
Issue Analytics
- State:
- Created 2 years ago
- Reactions:2
- Comments:5 (2 by maintainers)
Top Results From Across the Web
File Upload in ElectronJS - GeeksforGeeks
This tutorial will use the instance method of the dialog module to demonstrate File Upload functionality in Electron.
Read more >Working with files (I/O) in an Electron application - Medium
First of all, appDir is the directory path on the filesystem where the files uploaded on this application will be stored. The os....
Read more >Electron: get full path of uploaded file - node.js - Stack Overflow
Electron adds a path property to File objects, so you can get the real path from the input element using: document.
Read more >Electron.js File Upload with Full Path (Full Application Easy ...
Electron.js File Upload with Full Path (Full Application Easy and Simple Tutorial 2019)Download Source Code of the Application ...
Read more >Electron Drag and Drop File Upload Editing Application
Electron Drag and Drop File Upload Editing Application - Coding ShikshaDownload the Source Code of the Application ...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
I forgot to tell you that I was using playwright’s Electron() method to test our electron version of the app. i found some information on the electron website and they had added a path attribute to the File interface. see here
hi, @mxschmitt how about this function now, I met the same issue about the file path being empty in electron, did the playwright already solve it?