-
-
Notifications
You must be signed in to change notification settings - Fork 172
tgz support #1132
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
base: main
Are you sure you want to change the base?
tgz support #1132
Conversation
Would be very helpful for supporting Stainless packages in Val Town 👍 |
specifically preview versions, which we upload as tarballs to our own servers |
I've found that val town doesn't acquire types for any val town sdk's actually via esm.sh but yes for npm, but I'm not sure why. (To be fair our type acquisition is super janky, so it might not be worth designing around too much.) |
@stainless-em thanks, this is great! do you think we can remove the package name in the tgz path? like: - https://esm.sh/tgz/preact@https%3A%2F%2Fregistry.yarnpkg.com%2Fpreact%2F-%2Fpreact-10.26.6.tgz
+ https://esm.sh/tgz/https%3A%2F%2Fregistry.yarnpkg.com%2Fpreact%2F-%2Fpreact-10.26.6.tgz |
@stevekrouse i will look into it, can you please provide a code smaple for testing? Thanks🙏 |
Possibly, I tried that first actually. But then the PkgName in the EsmPath would need to be empty I think? Because there's no way to know what it is until the tarball is downloaded? idk |
makes sense, can you please check the CI? i'm love to the merge this after the CI passing. Thanks! |
tbc i think having the pkgname in the url is bad but i'm not familiar enough with how esm.sh is structured to know how to get rid of it 😅 |
adds support for .tar.gz files from arbitrary urls