Download the PHP package inclus16/laravel-dictionary without Composer

On this page you can find all versions of the php package inclus16/laravel-dictionary. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package laravel-dictionary

Laravel dictionary

Latest Version on Packagist Total Downloads

Laravel dictionary is a package, that manages access, validation and cache for your collection-based data.

A dictionary is a static (or nearly static) set of data that needs to be reread very often.

Prerequirements

PHP >= 8.5

Laravel >=13

Install

The package will automatically register a service provider Publish the package's configuration and translations by running:

Configuration

In .env file there constants that can be added:

DICTIONARY_DEFAULT_CACHE_STORE - see Laravel cache (default: array)

DICTIONARY_DEFAULT_CACHE_TTL - see Laravel cache (default: 3600)

Usage

The main class that you may work with is some classes that may be called DictionaryHandler.

This class must be registered in config dictionary.php:

Full methods of AbstractDictionaryHandler that can be extended:

Validation

For validation, you may use one of two rules:

This rule will search in dictionary {slug}, iterates over cached entities and compare value from request with {field} value from entity. If entity with equality will found - validation will be passed

This rule will search in dictionary {slug}, iterates over cached entities and compare value from request with {field} value from entity. If entity with equality does NOT found - validation will be passed

Access in code

Facade

Just one method. This will return a dictionary handler with this {slug}, or throw OutOfRangeException

DI

Inject \Inclus16\LaravelDictionary\Handler\HandlerFactory class

Static files

For optimization purposes you may call

this command with create json files that contains data of dictionary. for each dictionary there will be created a file, named {dictionarySlug}.json in disk from config: dictionary.publishDisk. Then you can handle this files directly via nginx as static files

Http access


All versions of laravel-dictionary with dependencies

PHP Build Version
Package Version
Requires php Version ^8.5
illuminate/console Version ^13.0
illuminate/support Version ^13.0
illuminate/http Version ^13.0
illuminate/validation Version ^13.0
illuminate/testing Version ^13.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package inclus16/laravel-dictionary contains the following files

Loading the files please wait ...