Replace jQuery in a website project with a 6KB alternative that uses the same familiar dollar-sign syntax.
Select and modify HTML elements, handle events, and change CSS styles without loading jQuery.
Build a partial bundle including only the Cash methods your project actually needs to reduce file size further.
Migrate an existing jQuery project to Cash using the provided migration guide.
Cash is a small JavaScript library that lets developers interact with webpage elements using the same style of code that jQuery popularized. jQuery became famous for simplifying how developers select and modify HTML elements on a page, but it grew large over time. Cash offers the same familiar syntax at a fraction of the file size, targeting modern browsers rather than very old ones. The size difference is meaningful. Cash comes in at 6 kilobytes when compressed and delivered over the web, compared to 24.4 kilobytes for a slimmed-down version of jQuery. This matters because every kilobyte a browser has to download adds a small delay before a page becomes interactive, and smaller files mean faster loads for visitors. The library supports selecting page elements by CSS selectors, chaining operations together, handling browser events, reading and writing HTML attributes, getting and setting CSS styles, manipulating the page structure by adding, removing, or moving elements, and working with forms. Most of the common day-to-day tasks that developers reach for jQuery to handle are covered here. Cash is written in TypeScript, which means its type definitions are generated directly from the source code rather than maintained separately by volunteers in a third-party registry. It also supports partial builds, where you can include only the specific methods your project actually uses to reduce the file size further. The library can be loaded from a content delivery network with a single script tag, or installed as a package through npm for use in bundled JavaScript projects. If you are already using jQuery and want to switch, the project provides a migration guide to help identify what is and is not available in Cash.
← fabiospampinato on gitmyhub — every repo by this author, as a profile.
Verify against the repo before relying on details.