TypeScript-DOM-lib-generator
TypeScript-DOM-lib-generator copied to clipboard
incomplete FileSystemHandle types
Please update types for File System Access API:
FileSystemDirectoryHandle is missing entries/values iterators
FileSystemFileHandle missing createWritable
FileSystemHandle is missing queryPermission and requestPermission
createWritable, queryPermission and requestPermission are not missing they are only supported in chromium so they are not added see for example https://developer.mozilla.org/en-US/docs/Web/API/FileSystemFileHandle/createWritable#browser_compatibility
For FileSystemDirectoryHandle is missing entries/values iterators on first I think you are right not 100% sure maybe that would just need a bump of the BCD version to be fixed...
FileSystemDirectoryHandle is missing entries/values iterators
This is because the generator does not support async iterable, but then as far as I know Blink is the only engine that supports this. I'm all for a PR for that part, though. (Hi @MattiasBuelens, do you want to try cherry-picking from #1135 for this?)
FileSystemDirectoryHandle has async iterable support in Blink (as of bug 1011539) and WebKit (as of bug 231142). So this does satisfy our criteria! 😄 (I'm a bit surprised that FileSystemDirectoryHandle got support before ReadableStream, but okay. 😛)
I'll look into reworking #1135.
Firefox supports FileSystemFileHandle.createWritable as of version 111. https://developer.mozilla.org/en-US/docs/Web/API/File_System_Access_API#browser_compatibility
(As a workaround there is @types/wicg-file-system-access)
#1521 fixed this. Blink-only permission things will probably not be added given other implementors are against them.
@github-actions close
Closing because @saschanaz is one of the code-owners of this repository.
In what library is this included? The types for (listing the contents of a directory)[https://developer.mozilla.org/en-US/docs/Web/API/File_System_API/Origin_private_file_system#listing_the_contents_of_a_folder] seem to be missing for me, I'm using: "lib": ["DOM", "DOM.Iterable", "ESNext"]
Created a new issue to not discuss in a closed issue https://github.com/microsoft/TypeScript-DOM-lib-generator/issues/1639