seffeng / php-format-helper by seffeng

PHP extension format helper
1,381
0
1
Package Data
Maintainer Username: seffeng
Maintainer Contact: save.zxf@gmail.com (seffeng)
Package Create Date: 2022-08-26
Package Last Update: 2023-08-03
Language: PHP
License: MIT
Last Refreshed: 2024-12-22 03:15:21
Package Statistics
Total Downloads: 1,381
Monthly Downloads: 21
Daily Downloads: 0
Total Stars: 0
Total Watchers: 1
Total Forks: 0
Total Open Issues: 0

PHP Helpers

安装

# 安装
$ composer require seffeng/format-helper

目录说明

|---src
|   |   Format.php
|   |---Traits
|           FormatTrait.php
|---tests
|       FormatTest.php

示例

/**
 * TestController.php
 * 示例
 */
namespace App\Http\Controllers;

use Seffeng\FormatHelper\Format;

class TestController extends Controller
{
    public function index()
    {
        var_dump(Format::sizeFormat(1024 * 1024 * 1024 * 1023));
    }
}

备注

1、更多示例请参考 tests 目录下测试文件。