prophp/params

PHP class for serving parameters

Maintainers

Details

gitlab.com/prophp/params

Source

Issues

Installs: 78

Dependents: 2

Suggesters: 0

Security: 0

Stars: 0

Forks: 0

Type:package

v0.0.1 2022-09-20 20:38 UTC

This package is not auto-updated.

Last update: 2024-05-29 04:29:15 UTC


README

  • PHP 8.0+

◦ Install

composer require prophp/params

◦ Create manually

▸ Take a look at README/Examples folder.

JsonParams.php extends ProPhp\Params

▸ Create same ...Params classes manually or ↓

◦ Render

▸ Install ...Params renderer

composer require prophp/render-params --dev

▸ Take a look at README/Examples folder.

JsonParams.render file was created manually

▸ Afterwards a terminal command bin/render params was run from a project's root (where composer.json file is located)

JsonParams.php file was generated automatically in the same folder where JsonParams.render file is located

NB! namespace is also generated automatically 🙂

◦ USE

▸ Take a look at tests/UnitTests/Params.php file.

◦ TEST

root ▸ docker/stop-all - optional

root ▸ docker/run - required only if your local PHP version is lower than 8.0

docker /var/www/htmlphp tests/UnitTests/Params.php

root ▸ docker/stop || docker/stop-all - required only if your local PHP version is lower than 8.0

bin/test-lite @todo LATER