diff --git a/CHANGELOG.md b/CHANGELOG.md index 38774f3e..27b0e924 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,18 @@ +## 0.8.0 (2014-05-27) + +Features: + + - Added Serializers with ArraySerializer, DataArraySerializer (default) and a provisional JsonApiSerializer. See [Issue #47]. + - Added `ResourceAbstract::setMeta('foo', mixed)` to allow custom meta data + - Replaced `Manager::setRequestedScopes()` with `Manager::parseIncludes('foo,bar')` which can be an array or CSV string. It can + also take "Smart Syntax" such as `Manager::parseIncludes('bars:limit(5|1):order(-something)')`, which can come from a URL query + param: `/foo?include=bars:limit(5|1):order(-something)`. + - Made all pagination (paginators and cursors) use meta output logic, so it sits with your custom meta data + - Moved `League\Fractal\Cursor\Cursor` and `League\Fractal\Cursor\CursorInterface` into `League\Fractal\Pagination`. + +[Issue #27]: https://github.com/thephpleague/fractal/issues/27 +[Issue #47]: https://github.com/thephpleague/fractal/pull/47 + ## 0.7.0 (2014-02-01) Features: diff --git a/README.md b/README.md index fe2c22bb..52dbb6f0 100644 --- a/README.md +++ b/README.md @@ -6,22 +6,23 @@ [![Latest Stable Version](https://poser.pugx.org/league/fractal/v/stable.png)](https://packagist.org/packages/league/fractal) Fractal provides a presentation and transformation layer for complex data output, the like found in -RESTful APIs, and works really well with JSON. +RESTful APIs, and works really well with JSON. Think of this as a view layer for your JSON/YAML/etc. When building an API it is common for people to just grab stuff from the database and pass it -to `json_encode()`. This might be passable for "trivial" API's but if they are in use by the public, -or used by an iPhone application then this will quickly lead to inconsistent output. +to `json_encode()`. This might be passable for "trivial" APIs but if they are in use by the public, +or used by mobile applications then this will quickly lead to inconsistent output. ## Goals * Create a "barrier" between source data and output, so schema changes do not affect users -* Systematic type-casting of data, to avoid foreach()ing through and (bool)ing everything -* Embed (or nest) relationships for complex data structures +* Systematic type-casting of data, to avoid `foreach()`ing through and `(bool)`ing everything +* Include (a.k.a embedding, nesting or side-loading) relationships for complex data structures +* Work with standards like HAL and JSON-API but also allow custom serialization * Support the pagination of data results, for small and large data sets alike * Generally ease the subtle complexities of outputting data in a non-trivial API -This package is compliant with [PSR-1][], [PSR-2][] and [PSR-4][]. If you -notice compliance oversights, please send a patch via pull request. +This package is compliant with [PSR-1], [PSR-2] and [PSR-4]. If you notice compliance oversights, +please send a patch via pull request. [PSR-1]: https://github.com/php-fig/fig-standards/blob/master/accepted/PSR-1-basic-coding-standard.md [PSR-2]: https://github.com/php-fig/fig-standards/blob/master/accepted/PSR-2-coding-style-guide.md @@ -48,9 +49,7 @@ The following versions of PHP are supported by this version. * PHP 5.4 * PHP 5.5 * PHP 5.6 - -HHVM support is also experimentally supported. It basically works, but CodeSniffer installation is screwing it up on -Travis-CI. +* HHVM ## Documentation @@ -61,7 +60,7 @@ Contribute to this documentation in the [sculpin branch](https://github.com/thep ## Todo - Wrap optional params in a ParamBag object or similar -- Complete JSON-API and HAL serializers +- Add JSON-API (kinda done) and HAL serializers ## Testing @@ -76,6 +75,7 @@ Please see [CONTRIBUTING](https://github.com/thephpleague/fractal/blob/master/CO ## Credits +- [Jason Lewis](https://github.com/jasonlewis) - [Phil Sturgeon](https://github.com/philsturgeon) - [All Contributors](https://github.com/thephpleague/fractal/contributors) diff --git a/composer.json b/composer.json index d308d060..80895abf 100644 --- a/composer.json +++ b/composer.json @@ -4,7 +4,8 @@ "keywords": [ "league", "api", - "json" + "json", + "rest" ], "homepage": "http://fractal.thephpleague.com/", "license": "MIT",