1/ In folder /server/src/config rename file config_example.js to config.js and add your own settings
2/ Install docker and Prisma cli. (https://www.prisma.io/docs/get-started/01-setting-up-prisma-new-database-a002/)
3/ In folder /server, run:
#init app
docker-compose up -d
#Deploy app
prisma deploy4/ In 3 different terminals:
# Prisma: Graphql and mySql (port 4000)
cd server
yarn install
yarn start# Media server: ExpressJs (port 8000)
cd media
yarn install
yarn start# Frontend: ReactJs (port 3000)
cd react
yarn install
yarn startGo to url: http://localhost:3000
- Scalable GraphQL server: The server uses
graphql-yogawhich is based on Apollo Server & Express - Pre-configured Apollo Client: The project comes with a preconfigured setup for Apollo Client
- GraphQL database: Includes GraphQL database binding to Prisma (running on MySQL)
- Tooling: Out-of-the-box support for GraphQL Playground
- Extensible: Simple and flexible data model – easy to adjust and extend
- Chat: Made with Prisma & apollo subscription. (WebSocket)
- Email management:
- Welcome email + link to validate the email
- Forget password email
- Signup management:
- Check password strength
- Send welcome email + link to validate the email
- App knows if email has been approved by the link
For a fully-fledged React & Apollo tutorial, visit How to GraphQL.
-
prisma reset -
docker container lslist container -
docker stop database_prisma_1stop container -
docker rm database_prisma_1remove container -
docker stop $(docker ps -a -q)stop all container -
docker rm $(docker ps -a -q)remove all container -
docker-compose up -dinit app -
prisma deployDeploy app -
eslint .Check JS/react syntax with eslint-plugin-react -
yarn startstarts GraphQL server onhttp://localhost:4000 -
yarn devstarts GraphQL server onhttp://localhost:4000and opens GraphQL Playground -
yarn playgroundopens the GraphQL Playground for theprojectsfrom.graphqlconfig.yml -
yarn prisma <subcommand>gives access to local version of Prisma CLI (e.g.yarn prisma deploy)
Note: We recommend that you're using
yarn devduring development as it will give you access to the GraphQL API or your server (defined by the application schema as well as to the Prisma API directly (defined by the Prisma database schema. If you're starting the server withyarn start, you'll only be able to access the API of the application schema.
Frontend:
- User interfaces: React https://reactjs.org/
- Design: material-ui-next https://material-ui-next.com/
- GraphQL tool: Apollo Client https://www.apollographql.com/
Backend:
- Server JS: ExpressJs http://expressjs.com/fr/
- Server GraphQL: GraphQL yoga https://github.com/prismagraphql/graphql-yoga
- ORM (object-relational mapping): Prisma https://www.prisma.io/
- Database MySQL: https://www.mysql.com/
- Send email: nodemailer https://nodemailer.com/
-Your feedback is very helpful, please share your opinion and thoughts! If you have any questions or want to contribute yourself, don't hesitate!
-Tests must be implemented. Feel free to create a PR :)
-Add a react hook as an example. https://reactjs.org/docs/hooks-intro.html
-Add a star to this Repo! It helps a lot!
If this project help you reduce time to develop, you can give me a cup of coffee :)















