Download the PHP package pnz/json-exception without Composer
On this page you can find all versions of the php package pnz/json-exception. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Please rate this library. Is it a good library?
Informations about the package json-exception
JSON-Exception
Usage
This library provides Json::decode()
and Json::encode()
implementations throwing \JsonException
on errors.
To use this library:
- install the library by using composer:
composer require pnz/json-exception
- replace the usage of
json_decode()
withJson::decode()
- replace the usage of
json_encode()
withJson::encode()
- catch the
\JsonException
eventually thrown by the functions
Example: Old code
new code:
Development
To run the PHP coding-styles checks (php-cs-fixer
and phpstan
) run the make phpcs
command to:
- download the
php-cs-fixer
tool intools/
(if not present) - download the
phpstan
tool intools/
(if not present) - Run
php-cs-fixer
on the source code - Run
phpstan
on the source code
To run the tests, use make tests
to
- download
phpunit
tool intools/
if not present - run
phpunit
tests
All versions of json-exception with dependencies
PHP Build Version
Package Version
Requires
php Version
^7.0 || ^8.0
ext-json Version *
ext-json Version *
The package pnz/json-exception contains the following files
Loading the files please wait ....