{"repo":"alexnault/classix","free":true,"listed":false,"github":"https://github.com/alexnault/classix","clone":"git clone https://github.com/alexnault/classix.git","description":"🏛️ The fastest and tiniest utility for conditionally joining classNames.","language":"TypeScript","stars":216,"topics":["class","classes","classname","classnames","clsx","css","tailwind","react","jsx"],"license":"MIT","category":"ui-components","readme_excerpt":"classix The fastest and tiniest utility for conditionally joining classNames. Installation Usage Use any amount of string expressions and classix will join them like so: Comparison Compared to other libraries, classix only allows string expressions as arguments: String expressions have a few benefits over objects: - A faster typing experience - A more intuitive syntax (conditions first) - else support through ternary operators What's more, by leveraging them, classix provides: - A simpler and consistent API - A smaller library size - Better performance Size Sources: classix, clsx, classnames Performance Sources: Ran benchmark on an AMD Ryzen 5 5600x with Node 20. Highlights - Supports all major browsers - Supports all versions of Node.js - Works with both ES Modules and CommonJS - Zero dependencies - Fully typed with TypeScript - Fully tested - Semver compliant Migrating to classix If you are using classnames or clsx , you can migrate to classix by changing your imports : And if you were using object arguments, you'll have to convert them to string arguments: That's it! Some love ❤️ \"This looks great. I agree that the object notation is not great and not worth the perf hit.\" — @jmeistrich \"It looks good! I like the idea that you can’t pass objects and is simple and minimal. I will use it on my next application instead of classnames.\" — @m0ment98 \"Thank you for creating and maintaining this package! It is great.\" — @charkour Changelog For a list of changes and releases, see th","default_branch":null,"files":null,"tree":[],"storefront":"/r/alexnault","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/alexnault/classix/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}