Closed achingbrain closed 9 months ago
Yeah, strictly only v1 and as yet I've not seen a compelling reason to do v2 in JS except for if someone wants to make a blockstore; although I think web3.storage has an implementation that uses v2 with indexes for something to do with unixfs paths.
Feel free to add a version
field, or a method if you think that makes more sense, it can just return a const 1
for now.
From what I can tell, this module will only create v1 CAR files and it doesn't provide a method to obtain the version of the file it's creating - please let me know if I've missed something obvious.
When returning a CAR file from an HTTP Gateway the spec says the
Content-Type
header should include the version number, e.g:It'd be great if we could hand that off to the writer, to reduce the chance of it getting messed up, something like: