spatie/unit-conversions
Lightweight PHP unit conversion library by Spatie. Currently supports weight conversion from kilograms to pounds via a fluent API: Weight::fromKilograms(100)->toLbs(). Install with Composer and extend as more units are added.
|
Package
|
Score
|
Description
|
Stars
|
Likes
|
Forks
|
Downloads
|
Issues
|
Score
|
Opportunity
|
License
|
Last Release
|
|
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| spatie/weight-conversions | 0.85 | Lightweight PHP package for converting between common weight units (e.g., grams, kilograms, pounds, ounces). Handy for apps needing consistent unit handling in calculations, forms, and APIs, with a simple, dependency-free API. | 4 | 4 | 2 | 0 | 0 | 1.0 | — | MIT | 4 years ago | |
| spatie/workshop-unit-conversions | 0.83 | Lightweight PHP package for performing unit conversions in Laravel or any PHP app. Install via Composer and convert values between supported units with a simple API. Includes tests, changelog, and MIT license. | 2 | 2 | 1 | 0 | 0 | 20.6 | — | MIT | 5 years ago | |
| akeneo/measure-bundle | 0.83 | — | 27 | 29 | 15 | 529 | 0 | 2.6 | 18.5 | MIT | 10 years ago | |
| frost/distance | 0.81 | PHP distance conversion library for US and metric units. Convert between mi, ft, in, km, m, cm, and mm (US↔metric, US↔US, metric↔metric). Simple fluent API: setUnit(), setDistance(), convertTo(). | 3 | 5 | 0 | 0 | 0 | 0.0 | — | MIT | — | |
| moontoast/math | 0.81 | PHP math utilities for Laravel and general use, offering convenient helpers for precise calculations, percentages, rounding, and numeric formatting. Lightweight and easy to integrate into apps where consistent arithmetic and number handling matter. | 456 | 365 | 7 | 147K | 1 | 2.3 | 24.4 | Apache-2.0 | 6 years ago | |
| gabrielelana/byte-units | 0.81 | — | 168 | 175 | 17 | 35K | 3 | 3.3 | 33.4 | MIT | 8 years ago | |
| php-units-of-measure/php-units-of-measure | 0.80 | PHP library for representing physical quantities and converting units (length, mass, etc.). Encapsulate values with their unit, convert via toUnit(), and accept quantities in any unit without hardcoding conversions. Composer install, PSR-4 autoloading. | 313 | 314 | 78 | 88K | 12 | 8.0 | 38.6 | MIT | 1 year ago | |
| lstrojny/hmmmath | 0.80 | PHP math utility package providing common numeric helpers and algorithms. Useful for calculations, statistics-like operations, and reusable math functions in Laravel or any PHP project. Lightweight, dependency-friendly, and easy to integrate into existing codebases. | 15 | 16 | 5 | 5K | 0 | 0.3 | 34.3 | — | — | |
| php-decimal/php-decimal | 0.80 | Reference Composer package for the PHP Decimal extension. Adds an implicit ext-decimal dependency, IDE stubs, and semantic versioning so you can require decimal support in your project with composer require php-decimal/php-decimal. | 78 | 78 | 1 | 29K | 2 | 0.8 | 35.3 | MIT | — | |
| midnightluke/php-units-of-measure-bundle | 0.79 | Symfony bundle integrating the php-units-of-measure library, providing unit definitions and services to work with quantities, conversions, and formatting in your app. Adds simple configuration and DI wiring for unit-of-measure support. | 2 | 2 | 3 | 13 | 4 | 1.1 | 10.8 | MIT | — | |
| cartalyst/converter | 0.79 | Cartalyst Converter is a PHP unit conversion library that makes it easy to convert values between measurement units (length, weight, volume, etc.). Includes extensible unit definitions, fluent API, and helpers to format results for applications and packages. | 88 | 91 | 29 | 18K | 1 | 7.0 | 32.3 | BSD-3-Clause | 1 year ago | |
| open-southeners/byte-unit-converter | 0.78 | PHP 8.1+ utility to convert byte sizes between multiple units with no dependencies. Inspired by macOS ByteCountFormatter, it helps format and convert storage values consistently for apps and libraries. | 5 | 5 | 0 | 141 | 0 | 1.8 | 19.4 | MIT | 2 years ago | |
| phlib/base_convert | 0.78 | Drop-in replacement for PHP base_convert that supports arbitrarily large numbers without silent failures. Convert big numeric strings between bases (e.g., 10↔36) reliably via Phlib\base_convert, and round-trip large values correctly. | 3 | 3 | 0 | 4K | 0 | 0.6 | 41.8 | LGPL-3.0 | 4 years ago | |
| akeneo/extended-measure-bundle | 0.78 | — | 3 | 3 | 4 | 11 | 0 | 0.2 | 5.6 | — | 9 years ago | |
| dtl/time-distance-bundle | 0.77 | — | 0 | 0 | 0 | 0 | 0 | 0.0 | — | — | — | |
| apie/type-converter | 0.77 | Apie Type Converter converts values and objects to other types, ideal for mapping between DTOs and domain objects. Includes a default converter factory and lets you register custom converters to handle your own conversion rules. | 0 | 0 | — | 866 | — | 0.0 | 43.4 | — | — | |
| becklyn/utilities | 0.77 | Utility helpers for PHP/Laravel projects: small, reusable functions and classes to simplify common tasks, improve developer ergonomics, and reduce boilerplate across your application and packages. | 0 | 0 | 0 | 134 | 0 | 21.4 | 34.5 | — | 2 weeks ago | |
| baks-dev/reference-clothing | 0.77 | — | 0 | 0 | 0 | 1 | 0 | 16.2 | 4.7 | MIT | 2 months ago | |
| rmiller/caser | 0.77 | PHP case manipulation utility for converting and formatting strings between common naming styles (e.g., camelCase, snake_case, kebab-case, StudlyCase). Lightweight helper for normalizing identifiers and labels in applications and libraries. | 0 | 0 | 0 | 16 | 0 | 0.0 | 17.0 | MIT | — | |
| spatie/tax-calculator | 0.77 | Interfaces and helpers to simplify tax calculations in PHP. Use TaxCalculation with plain numbers or items implementing HasTax to compute base, tax, and total prices, and combine calculations (e.g., cart items + delivery) on the fly. | 80 | 82 | 12 | 435 | 0 | 1.1 | 11.1 | MIT | 4 years ago |
How can I help you explore Laravel packages today?