daniele-zurico / Apollo2 Subscriptions How To
Apollo Server 2 how to setup subscriptions
Stars: ✭ 125
Programming Languages
typescript
32286 projects
Projects that are alternatives of or similar to Apollo2 Subscriptions How To
Nest User Auth
A starter build for a back end which implements managing users with MongoDB, Mongoose, NestJS, Passport-JWT, and GraphQL.
Stars: ✭ 145 (+16%)
Mutual labels: graphql, apollo-server, mongoose, mongodb
Intro To Graphql
[Course] Introduction to GraphQL
Stars: ✭ 175 (+40%)
Mutual labels: graphql, apollo-server, mongoose, mongodb
Graphql Advanced Projection
Fully customizable Mongoose/MongoDB projection generator.
Stars: ✭ 46 (-63.2%)
Mutual labels: graphql, apollo-server, mongoose, mongodb
Feathers Apollo
Feathers and Apollo Server Sample Project
Stars: ✭ 176 (+40.8%)
Mutual labels: graphql, apollo-server, mongodb
Apollo Opentracing
Performance trace your Apollo GraphQL server with Opentracing
Stars: ✭ 154 (+23.2%)
Mutual labels: graphql, apollographql, apollo-server
Frisky
🍿 Open Source GraphQL API for Online Shows
Stars: ✭ 161 (+28.8%)
Mutual labels: graphql, mongoose, mongodb
hano-graphql
GraphQL, Hapi and Node Project For Scaleable Apps.
Stars: ✭ 13 (-89.6%)
Mutual labels: mongoose, apollographql, apollo-server
Express Graphql Mongodb Boilerplate
A boilerplate for Node.js apps / GraphQL-API / Authentication from scratch - express, graphql - (graphql compose), mongodb (mongoose).
Stars: ✭ 288 (+130.4%)
Mutual labels: graphql, mongoose, mongodb
Fullstack Apollo Express Mongodb Boilerplate
💥A sophisticated GraphQL with Apollo, Express and MongoDB boilerplate project.
Stars: ✭ 301 (+140.8%)
Mutual labels: apollographql, apollo-server, mongodb
Create Social Network
An educational project, demonstrating how to build a large scalable project with Javascript.
Stars: ✭ 853 (+582.4%)
Mutual labels: graphql, apollo-server, mongodb
Next Graphql Blog
🖊 A Blog including a server and a client. Server is built with Node, Express & a customized GraphQL-yoga server. Client is built with React, Next js & Apollo client.
Stars: ✭ 152 (+21.6%)
Mutual labels: graphql, mongoose, mongodb
Graphql Nodejs Hapi Api
How to set-up a powerful API with Nodejs, GraphQL, MongoDB, Hapi, and Swagger
Stars: ✭ 116 (-7.2%)
Mutual labels: graphql, mongoose, mongodb
Nest Angular
NestJS, Angular 6, Server Side Rendering (Angular Universal), GraphQL, JWT (JSON Web Tokens) and Facebook/Twitter/Google Authentication, Mongoose, MongoDB, Webpack, TypeScript
Stars: ✭ 307 (+145.6%)
Mutual labels: graphql, mongoose, mongodb
Wertik Js
💪 A library that powers your app with GraphQL + Rest API
Stars: ✭ 56 (-55.2%)
Mutual labels: graphql, mongoose, mongodb
Boilerplate Vue Apollo Graphql Mongodb
Start your magical stack journey!
Stars: ✭ 85 (-32%)
Mutual labels: graphql, mongoose, mongodb
Graphql Mongoose Loader
GraphQL Mongoose Loader helpers
Stars: ✭ 98 (-21.6%)
Mutual labels: graphql, mongoose
React Fullstack Graphql
Starter projects for fullstack applications based on React & GraphQL.
Stars: ✭ 1,352 (+981.6%)
Mutual labels: graphql, apollographql
Vue Family Bucket Ssr Koa2 Full Stack Development From Meituan
🚀🚀2020最新Vue全家桶+SSR+Koa2全栈开发☁
Stars: ✭ 100 (-20%)
Mutual labels: mongoose, mongodb
Apollo server 2.0
This project is a good starting point for all the people that want to have apollo-server 2.0 ready to use. It integrates:
- queries
- mutations
- subscriptions (real-time data)
- authentication and authorisation (using google sign-on as provider server)
- schema stitching
- mongo db
- logger (it will create a file
error.log
and write on it in case of error - to change the level editcommon/util/logger.ts
lines 12, 13, 14 )
Installation:
-
install mongodb - refer to mongodb guide
-
npm install
Environment
In the root folder is available a file called .env
. It contains all the configuration environment for:
- mongodb
- google-sign-in as identity server for authentication and authorisation. More info available at http://www.dzurico.com/apollo-server-2-0-auth-with-google-signin/
available commands
- test environment:
npm run dev
(it will automatically rerun your code all the time you save and will check for tslint errors and formatting style errors.) - production environment:
npm run prod
How to configure prettier on your editor:
Webstorm
VS Code
prettier-vscode can be installed using the extension sidebar. Search for Prettier - Code formatter. It can also be installed using ext install prettier-vscode in the command palette.
Other editors
https://prettier.io/docs/en/editors.html
Playground
- Open your browser to this address: http://localhost:4000 and run the available commands:
- hello world
query {
hello
}
- fetch all the posts:
query {
posts {
author
comment
}
}
- add a new post
mutation {
addPost(author: "Daniele Zurico", comment: "www.dzurico.com") {
author
comment
}
}
- realtime data (Subscription) for post
subscription {
postAdded {
author
comment
}
}
- fetch all the users (you need to be authenticated with google identity server): For more information how to setup: http://www.dzurico.com/apollo-server-2-0-auth-with-google-signin/
query{
users {
id
name
surname
}
}
For a better explanation on how I setup this repo please refer to:
Note that the project description data, including the texts, logos, images, and/or trademarks,
for each open source project belongs to its rightful owner.
If you wish to add or remove any projects, please contact us at [email protected].