-
Notifications
You must be signed in to change notification settings - Fork 23
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Blob download not working as before #295
Comments
Can you share a repro where you create the The only difference in calls that I can tell is that in the |
You can also use void downloadData(Uint8List data, {required String filename}) {
web.HTMLAnchorElement()
..href = UriData.fromBytes(data, mimeType: 'text/plain').toString()
..setAttribute('download', filename)
..click()
..remove();
} Is using |
I am trying to update my app from dart:html to package:web
I had this function:
and updated it to this:
But the excel I want to download says it is corrupted and needs to be fixed to work.
I took a look at the resulting excel file in VSCode and found that there are subtle changes to some of the bytes randomly every time I run it. With the same code and the same data
For example the start line:
You can see that "&P" turned into "5P"
Additionally the file size increased 7x from 5kb to 36kb. This is due to the file ending in 27777 additional null characters
I attached both the the broken and the legit version as excel files
broken.xlsx
legit.xlsx
The text was updated successfully, but these errors were encountered: