Skip to content

A lightweight PHP toolkit for expressive backend/CLI apps

License

Notifications You must be signed in to change notification settings

salient-labs/toolkit

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

salient/toolkit

A lightweight PHP toolkit for expressive backend/CLI apps. May contain traces of Laravel.

Latest Stable Version License CI Status Code Coverage


Installation

Install the entire toolkit with Composer:

composer require salient/toolkit

Or install only the components you need, e.g. salient/cache, salient/utils and the toolkit's PHPStan extension:

composer require salient/cache salient/utils
composer require --dev salient/phpstan

Components

The Salient toolkit includes the following components, each of which can be installed separately to minimise the dependency footprint of your project. The only third-party dependencies are PSR interface packages and lkrms/dice, a standalone dependency injection container that will be removed when salient/container is finalised.

Salient toolkit component diagram

Component Package Provides
Cache salient/cache A key-value store backed by a SQLite database
CLI salient/cli A service container and command framework for CLI applications
Collections salient/collections Access to collections of values via array-like objects with chainable methods
Console salient/console Terminal output and message logging via an API similar to console in web browsers
Container salient/container A service container with contextual bindings
Contracts salient/contracts Interfaces, abstractions and enumerations
Core salient/core Reusable classes, traits and services
Curler salient/curler An HTTP client optimised for RESTful API endpoints
Db salient/db Access to databases
HTTP salient/http HTTP message and utility classes
Iterators salient/iterators Iterator classes and traits
PHPDoc salient/phpdoc A PHPDoc extractor and parser
PHPStan salient/phpstan* PHPStan extensions for development with the Salient toolkit
Polyfills salient/polyfills Polyfills
Sli salient/sli* sli, the toolkit's CLI utility
Sync salient/sync A framework and SQLite-backed store for synchronising data with backends
Testing salient/testing* Classes that are useful in test suites
Utils salient/utils Utility methods via stateless classes

* for development only

Documentation

API documentation for salient/toolkit tracks the main branch of the project's GitHub repository and is generated by ApiGen.

You can build it yourself by running the following commands in the top-level directory. Output is generated in docs/api by default.

composer -d tools/apigen install
tools/apigen/vendor/bin/apigen -c tools/apigen/apigen.neon

Other documentation is available under docs, and usage examples are provided in the form of unit tests.

License

This project is licensed under the MIT License.

About

A lightweight PHP toolkit for expressive backend/CLI apps

Resources

License

Stars

Watchers

Forks

Languages