Skip to content
This repository was archived by the owner on Mar 29, 2020. It is now read-only.

Commit da1c8ac

Browse files
committed
add schema generation to overview
1 parent 1724408 commit da1c8ac

File tree

2 files changed

+19
-3
lines changed

2 files changed

+19
-3
lines changed

config/config.php

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -35,9 +35,6 @@
3535
'schema' => [
3636
'path' => null,
3737
'output' => null,
38-
'types' => [],
39-
'mutations' => [],
40-
'queries' => []
4138
],
4239

4340
'controller' => 'Nuwave\Relay\Http\Controllers\LaravelController@query',

docs/Overview.md

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,4 +37,23 @@ Publish the configuration file
3737
php artisan vendor:publish --provider="Nuwave\Relay\LaravelServiceProvider"
3838
```
3939

40+
Create a ```schema.php``` file and add the path to the config
41+
42+
```
43+
// config/relay.php
44+
// ...
45+
'schema' => [
46+
'path' => 'Http/schema.php',
47+
'output' => null,
48+
],
49+
```
50+
51+
To generate a ```schema.json``` file (used with the Babel Relay Plugin):
52+
53+
```
54+
php artisan relay:schema
55+
```
56+
57+
*You can customize the output path in the ```relay.php``` config file under ```schema.output```*
58+
4059
For additional documentation, look through the docs folder or read the Wiki.

0 commit comments

Comments
 (0)