Creating A GraphQL Server With Node.js And Express

Поділитися
Вставка
  • Опубліковано 3 січ 2025

КОМЕНТАРІ •

  • @seancpp
    @seancpp 5 років тому

    I heard about graphql from the CodingBlocks podcast and this looks absolutely amazing. I can’t wait to get my hands dirty with this

  • @CallumAtwal
    @CallumAtwal 4 роки тому

    Thank you very much for this video! I've gone from 0 to having a good enough understanding on implementing a graphql API

  • @billwindsor4224
    @billwindsor4224 6 років тому +1

    Excellent GraphQL server configuration tutorial here, with several query structures to show GraphQL query configurations; *thank you, sir!*

  • @mussieteshome8232
    @mussieteshome8232 4 роки тому +1

    Clear and concise tutorial..thanks man!

  • @werneralonzo1230
    @werneralonzo1230 4 роки тому

    great example, I was confused but now I very clear how graphQL works, thanks dude.

  • @TheMezanine
    @TheMezanine 7 років тому +4

    Thanks very much again for this awesome introduction to GraphQL!!!

  • @EricBishard
    @EricBishard 5 років тому

    Excellent video, this is exactly what I needed to get familiar with GraphQL and Express! Such a great way to teach getting started...

  • @أبوعائشةالشامي-ف7ر
    @أبوعائشةالشامي-ف7ر 7 років тому +1

    clear and clean as every time.....another awesome tutorial

  • @r29Knight
    @r29Knight 4 роки тому +1

    The best tutorial! Thanks a lot for the help!

  • @mass13982
    @mass13982 6 років тому

    Excellent demonstration...very clear explanation...Thanks

  • @novanleon
    @novanleon 4 роки тому

    Excellent tutorial. Appreciate your excellent work.

  • @RealToughCandy
    @RealToughCandy 7 років тому +9

    Love it! Nice video. Have been looking for a n00b's walkthrough on implementing GraphQL and this was perfect.

  • @1123-p1y
    @1123-p1y 6 років тому +3

    Very nice and easy to understand and follow.

  • @ismailzafar
    @ismailzafar 5 років тому

    Great Graphql Introduction video

  • @kareemsaeed6562
    @kareemsaeed6562 4 роки тому

    In minute 42:23 instead of using both map and filter to get the updated course you can do it like this:
    const updateCourseTopic = arg => {
    let id = arg.id;
    let topic = arg.topic;
    let updatedCourse;
    coursesData.filter(course => {
    if(course.id === id){
    course.topic = topic;
    updatedCourse = course;
    }
    return course;
    });
    return updatedCourse;
    }
    Where you are only using filter on coursesData array

  • @menofculturehead9370
    @menofculturehead9370 3 роки тому

    nicely explained.. very well does the job!

  • @mohsenmadi3590
    @mohsenmadi3590 6 років тому

    Thank you Sebastian for this informative primer on GQL! It's not hard to predict that it would/should replace REST easily specially in newly built apps.

  • @daniellaerachannel
    @daniellaerachannel 7 років тому +1

    great tutorial as usual

  • @diwakarsingh9558
    @diwakarsingh9558 6 років тому +1

    Good explanation ... Nice video :)

  • @_MrMiyagi
    @_MrMiyagi 4 роки тому

    Very Very good !

  • @bennguyen1313
    @bennguyen1313 5 років тому +1

    Sorry, very basic question here.. so express.js runs on top of node.js.. but to use GraphQL you need another server, express-graphql? How does graphql-yoga or apollo-server-express fit in?
    For example, 'npm install' is used to install node.js modules, yet things like graphql-yoga are installed using 'yarn'.. so I assume it's not running on Node.js?

    • @otn987
      @otn987 5 років тому

      express-graphql is middleware for express, and express itself is nothing more than a frame work that makes your life easier than having to write server side code all from scratch. Node.js is an environment that allows javascript to run on a server.

  • @tedspens
    @tedspens 6 років тому

    Thank you for this excellent tut. GraphQL finally makes sense! :)

  • @manikmudholkar1165
    @manikmudholkar1165 4 роки тому

    It helped me a lot, Thank you

  • @gortee1000
    @gortee1000 6 років тому

    Great ! Exactly what am looking for in so many junks (y)

  • @raosezar889
    @raosezar889 3 роки тому +1

    for everyone have error express_graphql is not a function only change it to be like :
    const { graphqlHTTP } = require("express-graphql");
    and in app.use write like:
    app.use(
    "/graphql",
    graphqlHTTP({
    schema: schema,
    rootValue: root,
    graphiql: true,
    })
    );
    I hope it helpful

  • @iroekyjHD
    @iroekyjHD 2 роки тому

    in the newer express-graphql package use ``` const { graphqlHTTP } = require('express-graphql'); ```
    *edit* : also you will need an older version of graphql i think 15.3.0

  • @chucknor9708
    @chucknor9708 6 років тому +1

    Great video Sebastian. How would you extend this for an example where the data is not static and defined within the Server implementation but being called from a database? Thanks. Tam.

    • @seancpp
      @seancpp 5 років тому

      chuck nor
      You can use an ORM at the resolver step. Nothing changes about how you store and retrieve data-graphql doesn’t care about that. It’s just replacing your rest api
      If I’m wrong or mislead please correct me I’m very interested in this

  • @sumantkanala
    @sumantkanala 7 років тому +1

    Cool tutorial. Small suggestions would be use the shorthand object properties like: {schema, rootValue:...} instead of {schema:schema, etc...} which is redundant from ES6. Also replacing var with const is considered a good practice.

  • @hamdimiled4836
    @hamdimiled4836 6 років тому +1

    is possible to make Appllo like a controller in sequence diagram ?

  • @stilesndife8291
    @stilesndife8291 6 років тому

    Thanks a lot brother. well explained

  • @tentacle8148
    @tentacle8148 3 роки тому

    why do you use var?

  • @faridbangash75
    @faridbangash75 5 років тому

    sir how can we add different middlewares to graphql like isLoggedIn, hasPermission etc.

  • @SunilKumar-fh6jk
    @SunilKumar-fh6jk 6 років тому +2

    Hey sabastian, I have a request dude, please make a authentication tut using express graphql and react please. I'm stuck!

  • @ahmedabdelfatah8967
    @ahmedabdelfatah8967 6 років тому

    Thanks a lot it is a very helpful video

  • @Mephysto9292
    @Mephysto9292 6 років тому

    Really great job.. love u

  • @EdiiXHD
    @EdiiXHD 4 роки тому +2

    "Hello Wold!" xd

  • @alexanderdimitrov3765
    @alexanderdimitrov3765 4 роки тому

    "Unknow type int" error. Please help!

  • @gabrielgitonga1252
    @gabrielgitonga1252 2 роки тому

    Quick update
    Change this var express_graphql = require('express-graphql')
    To var express_graphql = require('express-graphql').graphqlHTTP;

  • @damiangilz
    @damiangilz 6 років тому

    Good video, but how do I get the result to display on the frontend?

  • @codingthesmartway
    @codingthesmartway  4 роки тому

    💻 Website: codingthesmartway.com/
    🎓 Top Web Development Online Courses: codingthesmartway.com/courses/

  • @timomuller6167
    @timomuller6167 6 років тому

    du bischt so n hammer erklärer, aber dein Englisch klingt sehr sehr deutsch :D Greets from Germany.

  • @迷彩网后
    @迷彩网后 7 років тому +2

    I think this tutorial still need to add babel and better file organization

    • @billwindsor4224
      @billwindsor4224 6 років тому

      @迷彩网后 Please clarify: "better file organization", be specific

  • @kodakodu
    @kodakodu 5 років тому

    hi
    just a tips:
    var root = {
    message: () => {
    return "Hello World";
    }
    };

  • @AkshayKumar-xd3fq
    @AkshayKumar-xd3fq 6 років тому

    Need to work on your "a"s and "um"s.

  • @rafaellima4136
    @rafaellima4136 5 років тому

    damn