daniel-de-wit/lighthouse-paperclip

Lighthouse GraphQL Directives for Paperclip attachment support

v5.0.0 2023-03-28 07:39 UTC

This package is auto-updated.

Last update: 2024-10-20 17:22:53 UTC


README

Latest Version on Packagist Software License Build Status Coverage Status Total Downloads

This package will add two directives that will support working with czim/laravel-paperclip.

Installation

You can install the package via composer:

composer require daniel-de-wit/lighthouse-paperclip

Usage

Apply the @attachment directive to get an url for the attachment.

type Blog {
    image: String @attachment
}

Apply the @variant to automatically generate an enum for available variant resizes.

type Blog {
    image(variant: _ @variant): String @attachment
}

Testing

composer test

Development (docker)

make setup
make test

PHP CLI

make app

Contributing

Please see CONTRIBUTING for details.

Credits

License

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