Это видео недоступно.
Сожалеем об этом.

How to use fetch in JavaScript: GET, POST, PUT and DELETE requests

Поделиться
HTML-код
  • Опубликовано: 13 авг 2024
  • 👉 Source code: openjavascript...
    ⚡ Looking for high-performance, affordable web hosting for your website or app? We use HostWithLove: bit.ly/3V2RM9Q ❤️
    In this video, we cover how to use JavaScript's in-built fetch method to make API requests: GET, POST, PUT and DELETE. We also extensively cover error-handing, both using catch and by querying the response object.
    #javascript #api #fetch #webdevelopment #programming
    ⚡ NEW: Web development courses from Meta Inc. ⚡
    Front-End Developer Professional Certificate: imp.i384100.ne...
    Back-End Developer Professional Certificate: imp.i384100.ne...
    iOS Developer Professional Certificate: imp.i384100.ne...
    Meta Android Developer Professional Certificate: imp.i384100.ne...
    Meta Database Engineer Professional Certificate: imp.i384100.ne...
    Website: openjavascript...
    Twitter: / openjavascript

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

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

    Thanks for watching!
    👉Source code and how to use fetch with async/await: openjavascript.info/2022/01/03/using-fetch-to-make-get-post-put-and-delete-

  • @gillesa290
    @gillesa290 2 года назад +1

    Fetch is now so easy ! Thank you for sharing.

  • @hananfadah
    @hananfadah 7 месяцев назад

    Thanks so much. I finally now understood the difference!

  • @sasikumar2554
    @sasikumar2554 2 года назад +2

    Well explained, clear and concise and it helps a lot for a beginner to understand with out breaking the head. Love the way you explain things. Thanks a lot. Keep up the good work!

    • @OpenJavaScript
      @OpenJavaScript  2 года назад

      Thanks for the feedback. Always try to keep the videos beginner-friendly :)

  • @michaelolawunmi464
    @michaelolawunmi464 2 года назад +2

    Thank you so much! This was one of the best explanations i found on this topic.

  • @febryramadhan1743
    @febryramadhan1743 2 года назад +1

    how could this vidieos only get 6 likes? its the best videos i found for https request.. subscribed!!!

    • @OpenJavaScript
      @OpenJavaScript  2 года назад

      Thank you for the feedback! And thanks for liking and subscribing - best way to support the channel :)

  • @roadtripper17
    @roadtripper17 2 года назад

    Your teaching style and content are just great.

  • @awakening7074
    @awakening7074 2 года назад +1

    Fantastic tutorial! Thank you so much!

  • @youssefosama973
    @youssefosama973 Месяц назад

    if there is an element consisits of 20 elms
    and want to update one of whom(16 as exapmle)
    i will use put method
    but i won't write all the 19 elms again
    so what is the best practice here??

  • @aminalamdarloo349
    @aminalamdarloo349 2 года назад +1

    Dear bro
    Tnx for your video .
    I need to know how i can appear the captcha code in busy or overloaded sites when tis not shown ( just show the image box not captcha code) by get and post method.

    • @OpenJavaScript
      @OpenJavaScript  2 года назад

      Did you find a solution to your question?
      Google has pretty good resources, maybe you find the answer there: developers.google.com/recaptcha

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

    Thanks for this video, very useful and helpful information, for someone that's just starting. However I was wondering, if you are using checkboxes to delete the values in the frontend, how would you incorporate that in the fetch Delete request?

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

      If you want to do this 'live', you will need to add event listeners to the checkboxes and make an API call every time a user checks or unchecks.
      But probably a better solution is to have a 'Save Settings' button that when clicked checks the values of the checkboxes and then makes an API call that feeds it that data. The exact nature of the request depends upon the API but if you can do some backend programming to support this it would be more efficient.

  • @jasonandrews7080
    @jasonandrews7080 2 года назад +1

    Very clear tutorial ! Can you share the sample code please?

    • @OpenJavaScript
      @OpenJavaScript  2 года назад

      Thank you for the feedback!
      You can find the sample code for all fetch request types on my website:
      openjavascript.info/2022/01/03/using-fetch-to-make-get-post-put-and-delete-requests/

  • @mohammadhosseinkhanzadi6701
    @mohammadhosseinkhanzadi6701 2 года назад +1

    thank you man

  • @codecobber1107
    @codecobber1107 2 года назад

    Just brilliant, thanks

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

    Very helpful

  • @dzajakeks5539
    @dzajakeks5539 2 года назад +1

    where async / await

    • @OpenJavaScript
      @OpenJavaScript  2 года назад +1

      Async/await using Fetch: ruclips.net/video/8JcCdp2Y4Q4/видео.html&t

    • @dzajakeks5539
      @dzajakeks5539 2 года назад

      @@OpenJavaScript thank you for the link