A Bower-less asset manager for Sprockets that downloads and packages JavaScript and CSS libraries for Ruby web applications.
Torba is a Ruby gem that acts as an asset manager for Sprockets, designed to replace Bower for managing JavaScript and CSS libraries in Ruby web applications. It downloads libraries from remote sources, caches them locally, and integrates them into Sprockets' load path, simplifying frontend dependency management without external tools.
Ruby developers using Sprockets in frameworks like Rails or Sinatra who need a lightweight, integrated solution for managing frontend assets without relying on Bower or complex gem wrappers.
Torba offers a minimal, Ruby-native alternative to Bower and gem-wrapped assets, reducing maintenance overhead and avoiding dependency on external ecosystems while providing straightforward asset packaging and Sprockets compatibility.
Bundler for Sprockets
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.
Torba directly downloads assets from sources like GitHub releases or npm, eliminating the need for Bower and simplifying the dependency chain as highlighted in its philosophy.
It seamlessly places assets under Sprockets' load path, allowing easy require or import directives in application JavaScript and CSS files without extra configuration.
Each package is stored in a namespaced directory, preventing asset name collisions in the shared Sprockets filesystem, as described in the 'Packing the torba' process.
The :import option lets you cherry-pick specific files with glob patterns, flattening structures for cleaner require directives, as shown with the lightslider example in the README.
Torba doesn't resolve dependencies; you must specify exact versions in Torbafile, which the README admits as a design limitation, leading to potential errors and maintenance overhead.
Every asset change requires running `bundle exec torba pack` manually, which disrupts development flow and isn't automated like modern package managers.
It depends on external tools like curl, unzip, gzip, and tar, adding setup complexity and potential cross-platform issues, as noted in the 'External dependencies' section.
Torba is an open-source alternative to the following products:
A Ruby on Rails gem that integrates Bower package management into Rails asset pipeline for front-end dependency handling.
rails-assets is a service that automatically converts Bower packages into Ruby gems, making it easy to use front-end JavaScript/CSS libraries in Rails applications.