subdomains/blog/_posts/2019-06-18-global-installs-done-right.md
We built Volta to make managing, sharing, and using JavaScript command-line tools convenient and reliable. To make this work, we had to tackle the problem of global installs: a simple way to distribute command-line binaries but with issues that cause some developers to shy away from using them. Volta makes global installs a first-class part of the JavaScript tooling experience, making them both convenient and safe to use.
<!--more-->So why do folks avoid global installs in the first place?
dependencies or devDependencies, making it harder for other developers to contribute.Some experts advocate including any tools your project depends on in your dependencies and then using the scripts hash in package.json to facilitate running those tools. This way any developer using your code will be able to easily run the same versions of the same tools that you do. This solution, while powerful, is not without its own issues:
npm test vs mocha)create-react-app.Volta solves both of these sets of problems by providing smart proxies for any and all of your JS tools.
volta install mocha, you let Volta know that you want mocha to be available everywhere in your terminal. Volta will download the latest version (or if you want you can specify a specific version) to use as the default.mocha directly in your terminal, just as if you had globally installed it with npm.mocha in a project that has the mocha package as a dependency, Volta will automatically delegate to the local version installed in node_modules, without you having to change the command at all.This proxy behavior lets you get all the usefulness of having tools directly available in your terminal, without having to worry about switching versions when switching projects. As a bonus, Volta will also pin a version of Node when installing each tool, so you don’t have to worry about having to re-install the tools if you update your default version of Node—they will all continue to work!
To learn more and try Volta for yourself, check out our home page https://volta.sh. You can also reach us on Twitter @usevolta or join our Discord https://discord.gg/hgPTz9A