pulled from figma comment
As a result, in the browser we'll need to fetch https://$spdomain/piece/$filecoinPieceCid, which gives us the CAR that was uploaded. The CAR then needs to be process by JS car library and JS triggers a file save to the OS for "filecoin-corgi.png".
We should be able to do stream the download from the SP into a car reader, which then transforms parsed content for the file, and then stream the actual content bytes with proper filetype are streamed to the users machine.
There will likely be some intermediary memory usage growth while parsing the car and then walking the dag for cars containing multiple files. (we could use indexeddb blockstore to cache this for this usecase?)
pulled from figma comment
We should be able to do stream the download from the SP into a car reader, which then transforms parsed content for the file, and then stream the actual content bytes with proper filetype are streamed to the users machine.
There will likely be some intermediary memory usage growth while parsing the car and then walking the dag for cars containing multiple files. (we could use indexeddb blockstore to cache this for this usecase?)