| 
				
					 | 
			há 8 anos atrás | |
|---|---|---|
| .. | ||
| .babelrc | há 8 anos atrás | |
| .gitignore | há 8 anos atrás | |
| LICENSE.txt | há 8 anos atrás | |
| README.md | há 8 anos atrás | |
| index.js | há 8 anos atrás | |
| package.json | há 8 anos atrás | |
| schema.js | há 8 anos atrás | |
| swapi.js | há 8 anos atrás | |
| yarn.lock | há 8 anos atrás | |
A GraphQL endpoint for the Star Wars API, generated from the JSON Schema provided.
Install with:
npm install
Run with:
npm start
Go to the following URL in your browser to see GraphiQL:
Here's an example of a query you can run:
{
  people {
    name,
    starships {
      name,
      length
    }
  }
}
The server console will print a list of all of the URLs fetched. Thanks to dataloader, we only request each URL once instead of loading it for each subtree of the query.