3 ways to build a Flight Widget! (JavaScript + Node.js + REST API + Database)

Поделиться
HTML-код
  • Опубликовано: 10 сен 2024

Комментарии • 64

  • @aniakubow
    @aniakubow Год назад +57

    Thanks so much for all your kind words and support! Hope you can check out my channel too for some cool projects 🎉

    • @AbdennourKhelfi
      @AbdennourKhelfi Год назад +1

      my mentor ♥️🙏🏻

    • @ImInYourBrains
      @ImInYourBrains Год назад

      Lol at the judgmental look you gave us at 46:08 when you said "its the body we are going to want to insert .. (pause)...."
      Hey, its not our fault! The internet made us all this way.

    • @alfarrouq9756
      @alfarrouq9756 Год назад

      You’re amazing this tutorial really helped me understand API’s thank you!

  • @godwinebikwo6544
    @godwinebikwo6544 Год назад +76

    Targaryens now tracking planes hmm

  • @kia808
    @kia808 Год назад +2

    I am learning JavaScript, this project is of great help to understand the actual working. Thanks a ton dear for helping me in my journey ❤❤❤❤ love & peace to you 😇😇😇😇

  • @BonetheBaker
    @BonetheBaker Год назад +3

    if anyone is getting a Access-Control-Allow-Origin error in 1:07:45 you just need to add to your server.js file
    app.use(cors({
    origin: '*'
    }));
    leave the * as is or change it to your 'localhost:8000/flights'

  • @orlandofuorios
    @orlandofuorios Год назад

    Thanks so much for your efforts ...

  • @Euphoniumstar
    @Euphoniumstar Год назад +5

    Hey guys, if you start getting a weird "status code 500" error and the API data just stops being retrieved, there's a chance there's nothing wrong with your code and the API itself is just down. Nothing really to do but wait for it to come back online.

    • @dragosbaluta288
      @dragosbaluta288 Год назад

      Hey Steve, any tips on how I could check whether the issue is with the API rather my code ?I'd really appreciate it.

  • @Tomis_C
    @Tomis_C Год назад

    Just Fantastic 😍 Excellent video!🔥🔥🔥

  • @ativerc
    @ativerc Год назад

    That autocomplete is really nice. Aggressive but nice!

  • @rahberhussain7929
    @rahberhussain7929 Год назад +2

    those who facing issue of typeerror:cannot find properties undefined try this may it will work
    i just removed the .default from the axios and it's working try this out
    const axios = require('axios')
    instead of
    const axios= require('axios'). default

  • @Ali-lm7uw
    @Ali-lm7uw Год назад +2

    Lanisters send their regards

  • @Krt506
    @Krt506 Год назад

    Ania dziękujemy! Jesteś the best :)

  • @Hacking-NASSA-with-HTML
    @Hacking-NASSA-with-HTML Год назад

    FreeCodeCamp rocks 😎👍 So good quality !!! Thank you very much, Anna! We really appreciate it!❤

  • @MW-ze9jm
    @MW-ze9jm Год назад +1

    I'm getting this error in the second project at 1:04:22, instead of the flights.
    TypeError: Cannot read property 'request' of undefined
    at /Users/blabla/WebstormProjects/flightWidget1/server.js:18:11
    The line in question is:
    axios.request(options).then(function (response) {
    But that's part of the code snippet from the API, what could it be?

    • @prathamvyas8342
      @prathamvyas8342 Год назад

      same problem

    • @MW-ze9jm
      @MW-ze9jm Год назад +1

      @@prathamvyas8342 I moved const axios = require("axios") from the top of the file in server.js into the app.get above the const options = {
      Now I see the data in the WebStorm Terminal.
      However, localhost:8000/flights keeps loading forever.

    • @raihanr2985
      @raihanr2985 Год назад

      @@MW-ze9jm have you solved the problem?

    • @MW-ze9jm
      @MW-ze9jm Год назад +1

      @@raihanr2985 not really, data showed up in my terminal but it kept loading on the localhost forever, so I gave up.

    • @georgieadolphe4095
      @georgieadolphe4095 Год назад

      Ugh, having the same problem. Req is declared but it's value is never read

  • @grotsunfull
    @grotsunfull Год назад +2

    Great job!

  • @panagiotisg83
    @panagiotisg83 Год назад

    I haven't seen the ?.map() notation before. What exactly does it do and what is it called? I can't seem to find much on Google.

  • @zdfvbadfbadb
    @zdfvbadfbadb Год назад +1

    For the pure JS project, the problem with the time display when adding a new randomly generated flight is due to displayHour being set equal to hour before hour is incremented. Updating the generateTime() function as shown below fixes this bug:
    function generateTime() {
    hour++
    if (hour >= 24) {
    hour = 1
    }
    const displayHour = (hour < 10) ? "0" + hour : hour
    return displayHour + ":" + generateRandomNumber(5) + generateRandomNumber()
    }

  • @harsh-alashi
    @harsh-alashi Год назад +1

    Great Course Thanks

  • @jianlingao7720
    @jianlingao7720 Год назад

    Thanks!

  • @nikolaivanovic8851
    @nikolaivanovic8851 Год назад

    Hey guys, can someone explain why she uses server.js to call that airport api., and then from script uses fetch to get that data? Can u do it without server, just (in the script) fetch(airport.api).
    Thank you very much :)

  • @ashique12009
    @ashique12009 Год назад

    Good one, but why you remove all semicolons?
    We know in JS semicolon is not mandatory but if it would be there then what will be the issue?
    Thanks.

  • @ketz555
    @ketz555 Год назад

    Is there an similar API that doesn't take your card details?

  • @momithachoubey786
    @momithachoubey786 Год назад

    I came here for her❤️❤️❤️

  • @willhurricane9yearsago790
    @willhurricane9yearsago790 Год назад

    Could make a beef programming language video

  • @kevinscottbatchelor
    @kevinscottbatchelor Год назад

    Thanks so much for this video!
    I copied the code base exactly and I am getting an issue with:
    const word = Array.from(flightDetails[flightDetail])
    It is saying: TypeError: undefined is not iterable (cannot read property Symbol(Symbol.iterator))
    Any ideas as to why?

    • @MrOrganicz
      @MrOrganicz Год назад

      did you fix the issue, if so could you help me with it?

  • @harsha4074
    @harsha4074 Год назад

    regular expressions course plss

  • @aymannaeem
    @aymannaeem Год назад

    can working with rapido api

  • @BernhardHofmann
    @BernhardHofmann Год назад

    Kinda cool, but it's a long way off a split flap emulator.

  • @quachhengtony7651
    @quachhengtony7651 Год назад +1

    Why did I read the thumbnail as "3 ways to fight midget"

  • @dainelgarciga9814
    @dainelgarciga9814 Год назад

    Cool❤🖒

  • @demicoderr
    @demicoderr Год назад

    Fourth...great video by the way!

  • @dennis.teevee
    @dennis.teevee Год назад

    ♥️🌷

  • @Thzin797
    @Thzin797 Год назад

    Hello.

  • @jf1341
    @jf1341 Год назад

    👌👌🙏🙏💯

  • @indofiz1077
    @indofiz1077 Год назад +1

    Drakaryyysssss

  • @adeelahmed8991
    @adeelahmed8991 Год назад

    10th
    first double digit

  • @wooly_destroy
    @wooly_destroy Год назад +3

    first

  • @onwukarosariow1607
    @onwukarosariow1607 Год назад +1

    Pov you cane her but your not interested in coding

  • @marcinmarcin5802
    @marcinmarcin5802 Год назад

    ania kubOŁ lol

  • @akpewlfried2123
    @akpewlfried2123 Год назад

    second

  • @zero3814
    @zero3814 Год назад

    8th 😁