Download the PHP package jbernavaprah/lighthouse-translation without Composer
On this page you can find all versions of the php package jbernavaprah/lighthouse-translation. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Table of contents
Download jbernavaprah/lighthouse-translation
More information about jbernavaprah/lighthouse-translation
Files in jbernavaprah/lighthouse-translation
Download jbernavaprah/lighthouse-translation
More information about jbernavaprah/lighthouse-translation
Files in jbernavaprah/lighthouse-translation
Vendor jbernavaprah
Package lighthouse-translation
Short Description Translation support for Laravel Lighthouse
License MIT
Package lighthouse-translation
Short Description Translation support for Laravel Lighthouse
License MIT
Please rate this library. Is it a good library?
Informations about the package lighthouse-translation
Lighthouse Translation
Is not PRODUCTION READY.
- Requirements
- Installation
- Usage
Requirements
Installation
1. Install using composer:
2. UseTranslation
Apply the JBernavaPrah\Translation\UseTranslation
trait to your models.
3. Declare field type as Translate
on GraphQL schema
Usage
Enable Translation
The directive localize
accepts as a parameter the lang to use to return the
localized data.
If is not founded on the column, null is returned.
In case the directive is not used on that query/mutation, the RawTranslation type is returned.
Credits:
A lot of ideas came thanks to daniel-de-wit/lighthouse-sanctum. Big thanks to him and his beautiful code!
Also the authors of nuwave/lighthouse did a great job on the documentation and code.
All versions of lighthouse-translation with dependencies
PHP Build Version
Package Version
Requires
php Version
^8.1
laravel/framework Version ^9.0
nuwave/lighthouse Version ^5.5
spatie/data-transfer-object Version ^3.7
laravel/framework Version ^9.0
nuwave/lighthouse Version ^5.5
spatie/data-transfer-object Version ^3.7
The package jbernavaprah/lighthouse-translation contains the following files
Loading the files please wait ....