marqant-lab/graphql-custom-scalars

Package with GraphQL custom Scalar types.

v0.0.1 2020-12-21 11:09 UTC

This package is auto-updated.

Last update: 2024-04-21 18:29:18 UTC


README

Description

This package contains GraphQL custom Scalar types.

Available types:

  • DateTime: format the date as ISO8601.

Installation

Require the package through composer.

composer require marqant-lab/graphql-custom-scalars

After this you need to import graphql schema.
For this add next row to your graphql/schema.graphql or graphql/modules.graphql:

#import ../vendor/marqant-lab/graphql-custom-scalars/graphql/*.graphql

Tests

If you need tests for this package into your project you can add to your phpunit.xml:

        <testsuite name="MarqantGraphQLDateTimeScalar">
            <directory suffix="Test.php">./vendor/marqant-lab/graphql-custom-scalars/tests</directory>
        </testsuite>