2017 © Pedro PelĂĄez
 

library laravel-json-response

Quickly make JSON responses in Laravel

image

witify/laravel-json-response

Quickly make JSON responses in Laravel

  • Monday, May 14, 2018
  • by francoislevesque
  • Repository
  • 2 Watchers
  • 0 Stars
  • 31 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 4 Versions
  • 182 % Grown

The README.md

Quick JSON reponses in Laravel

Latest Version on Packagist Build Status Maintainability Test Coverage Total Downloads, (*1)

Installation

You can install the package via composer:, (*2)

composer require witify/laravel-json-response

Usage

Add it to your controller: ``` php, (*3)

use Witify\LaravelJsonReponse\JsonTrait;, (*4)

class ApiController extends Controller { use JsonTrait; }, (*5)


## Available methods | Method | Description | | --- | --- | | setStatusCode(int $statusCode) | Set the status code of the response | | getStatusCode(int $statusCode) | Get the status code of the response | | response($data, $headers = []) | Create a json response | | success($message = "", $data = null) | Create a successful json response | | error($message = "", $data = null) | Create a failed json response | ### Testing ``` bash composer test

Changelog

Please see CHANGELOG for more information what has changed recently., (*6)

Contributing

Please see CONTRIBUTING for details., (*7)

Security

If you discover any security related issues, please email info@witify.io instead of using the issue tracker., (*8)

Credits

License

The MIT License (MIT). Please see License File for more information., (*9)

The Versions

14/05 2018

dev-master

9999999-dev https://github.com/Witify/laravel-json-response

Quickly make JSON responses in Laravel

  Sources   Download

MIT

The Requires

 

The Development Requires

laravel json responses

14/05 2018

1.0.1

1.0.1.0 https://github.com/Witify/laravel-json-response

Quickly make JSON responses in Laravel

  Sources   Download

MIT

The Requires

 

The Development Requires

laravel json responses

14/05 2018

1.1.0

1.1.0.0 https://github.com/Witify/laravel-json-response

Quickly make JSON responses in Laravel

  Sources   Download

MIT

The Requires

 

The Development Requires

laravel json responses

14/05 2018

1.0.0

1.0.0.0 https://github.com/Witify/laravel-json-response

Quickly make JSON responses in Laravel

  Sources   Download

MIT

The Requires

 

The Development Requires

laravel json responses