Skip to content

Starwars GraphQL API + Twig templates Blazon example

Notifications You must be signed in to change notification settings

linkorb/starwars-blazon

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Starwars GraphQL API + Twig templates Blazon example

This directory contains a complete example for publishing a static website based on data retrieved from the following GraphQL API:

Directory structure

The example defines queries (for retrieving films and characters) in the graphql/ directory.

Twig Templates for visualising the query responses are stored in the templates/ directory.

The src/PublicationFactory.php file defines a custom Publication factory that executes the queries and constructs the publication for publishing.

Publishing

Use the following command to generate a static website in the build/ directory with verbose output:

# install php dependencies into vendor/
composer install

# run blazon to publish into build/
vendor/bin/blazon publish -vv

Brought to you by the LinkORB Engineering team


Check out our other projects at linkorb.com/engineering.

Btw, we're hiring!

About

Starwars GraphQL API + Twig templates Blazon example

Resources

Code of conduct

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published