JSON encoding & decoding library
Table of contents
Installation
composer require weew/json-encoder
Introduction
This is a very simple wrapper around the json_encode
and json_decode
functions that additionally supports various data types and provides catchable encoding & decoding exceptions in case of a JSON error.
Usage
$encoder = new JsonEncoder();
$encoder->encode(/** data **/);
$encoder->decode(/** json **/);