Skip to content
This repository has been archived by the owner on Jul 15, 2019. It is now read-only.

An example app using React, Tornado, and GraphQL

License

Notifications You must be signed in to change notification settings

yatsu/react-tornado-graphql-example

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

24 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

react-tornado-graphql-example

A personal one-shot example app using React, Tornado, and GraphQL.

The subscription code is not working.

Setup

Install NPM packages:

% npm install

Install pip packages and register tornado-graphql-example pacakge:

% cd tornado
% pip install -r requirements.in
% python setup.py develop

Usage

Launch the GraphQL API server:

% tornado-graphql-example

Launch the development web server which serves the static client-side app:

% npm start

Development

--debug option enables auto-start on modifying files:

% tornado-graphql-example --debug

By default, all origins are allowed to CORS. Be sure to configure the following options.

  • allow_origin (default '*') or allow_origin_path
  • allow_credentials (default True)

Frameworks/Libraries

Client-side (JavaScript)

The application code was generated by create-react-app.

See package.json for more information.

Server-side (Python)

See tornado/requirements.in for more information.

Todo

  • Create the independent tornado-graphql module same as flask-graphql
  • Add missing GraphQL features and make the code robust
  • GraphiQL integration
  • Tests
  • Background job processing using ZeroMQ (Tornado really shines with this!)
  • Authentication
  • GraphQL subscription

Related Work

About

An example app using React, Tornado, and GraphQL

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published