wasm-pack icon indicating copy to clipboard operation
wasm-pack copied to clipboard

Allow for custom URL for binary downloads via NPM

Open MM-coder opened this issue 8 months ago • 0 comments

As discussed in #605, the ability to be able to specify a custom URL for binary downloads is instrumental when working in certain environments, for example, my company blocks Github even when going through a proxy.

This PR includes three environment variables that allow for over-riding the URL and certain download aspects of the current vendoring script, namely:

  • WASMPACK_CUSTOM_URL (allowing {{author}}, {{name}}, {{version}}, and {{platform}} placeholders)
  • WASMPACK_REPO_AUTHOR to override the default author
  • WASMPACK_REPO_NAME to override the default name

Make sure these boxes are checked! 📦✅

  • [X] You have the latest version of rustfmt installed
$ rustup component add rustfmt
  • [X] You ran cargo fmt on the code base before submitting
  • [X] You reference which issue is being closed in the PR text

✨✨ 😄 Thanks so much for contributing to wasm-pack! 😄 ✨✨

MM-coder avatar Apr 20 '25 08:04 MM-coder