Skip to content
This repository has been archived by the owner on Jul 28, 2024. It is now read-only.
/ utils Public archive

๐Ÿ›  Useful PHP utilities and helpers

License

Notifications You must be signed in to change notification settings

wavevision/utils

Repository files navigation

Wavevision s.r.o.

Utils

CI Coverage Status PHPStan

Set of useful PHP utilities and helpers extending nette/utils.

Installation

Via Composer

composer require wavevision/utils

Contents

The package contains useful classes for:

  • Arrays โ€“ array helpers (manipulate, sort, extract etc.)
  • ContentTypes โ€“ format extensions and filenames for content types
  • DOM โ€“ create and format data attributes for HTML elements
  • ExternalProgram โ€“ simple external command runner
  • FileInfo โ€“ get file info (basename, dirname, extension etc.)
  • Finder โ€“ adds sorting to nette/finder
  • ImageInfo โ€“ get image content type and size
  • ImmutableObject โ€“ combines Nette\SmartObject and withMutation helper
  • Json โ€“ JSON pretty encoder with PHP and JavaScript indents
  • Objects โ€“ dynamic get / set, get namespace, classname etc.
  • Path โ€“ join path parts, stringify path object etc.
  • SerialNumber โ€“ generate serial numbers from year and custom numbers
  • Server โ€“ access some useful server info (e.g. file upload limit)
  • Strings โ€“ string helpers (encode, transform etc.)
  • Tokenizer โ€“ get structure from file (e.g. a class)
  • Validators โ€“ validate Czech and Slovak numbers (phone, personal, business)
  • Zip โ€“ simple ZIP archive helper (compress, extract)