Skip to content

3.8.0

Choose a tag to compare

@binaryk binaryk released this 30 Jun 11:36
· 125 commits to 3.x since this release

Added

  • RestResponse static index method, so you can return the same format for a custom paginator.
$paginator = User::query()->paginate(5);

$response = Binaryk\LaravelRestify\Controllers\RestResponse::index(
    $paginator
);

Changed

  • Signature of the resolveIndexMainMeta method, now it accept the paginatorMeta information:
public function resolveIndexMainMeta(RestifyRequest $request, Collection $items, array $paginationMeta): array