承接 axn/laravel-extension 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

axn/laravel-extension

最新稳定版本:11.3.1

Composer 安装命令:

composer require axn/laravel-extension

包简介

Includes a set of useful tools for the Laravel framework.

README 文档

README

Includes a set of useful tools for the Laravel framework.

Documentation

Installation

With Composer:

composer require axn/tool-kit-for-laravel

To use some of these tools you must have correctly installed the package forxer/generic-term-translations-for-laravel already prerequisite by this package (therefore present).

Use the locales publisher of Laravel Lang to add/update/reset or remove translations:

Quick Reference

Helpers

Helper Description
app_env_enum() Get standardized environment enum
app_env_name() Get standardized environment name
carbon() Create Carbon instance from various formats
collect_models() Create Eloquent collection
str_html() Create HtmlString instance
linebreaks() Normalize line endings to UNIX format
nl_to_br() Alias of nl2br()
nl_to_br_compact() Convert consecutive newlines to single <br>
nl_to_p() Convert newlines to paragraphs
nl_to_p_flat() Convert text to single paragraph with <br>
number_formatted() Format number with locale
compute_dec_to_time() Decimal to time array
convert_dec_to_time() Decimal to time string
human_readable_bytes_size() Format bytes to human readable
mime_type_to_fa5_class() MIME type to FontAwesome 5 icon
mime_type_to_fa6_class() MIME type to FontAwesome 6 icon
mime_type_to_fa7_class() MIME type to FontAwesome 7 icon
trans_ucfirst() Translate with first char uppercase
is_valid_model() Check if class is valid Eloquent model
semver_to_id() Convert semver to numeric ID

Blade Directives

Directive Description
@nltobr() Convert newlines to <br>
@nltobrcompact() Convert consecutive newlines to single <br>
@nltop() Convert newlines to paragraphs
@nltopflat() Convert to single paragraph with <br>

Components

Component Description
<x-required-field-marker /> Display required field indicator

Enums

Enum Description
AppEnv Standardized environment names
Civilities Form civilities (Mrs, Mr)

Requirements

  • PHP 8.4+
  • Laravel 12.x

License

MIT

统计信息

  • 总下载量: 2.86k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 1
  • 点击次数: 0
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 2
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2016-03-22