---
title: "All in one! Javascript promises…"
url: https://daily.dev/posts/all-in-one-javascript-promises--j20xzbhnu
source_url: https://medium.com/dhiwise/all-in-one-javascript-promises-77b5bd7c7c61?source=rss------javascript-5
type: article
source: "Medium"
published: 2022-02-23T19:56:33.357Z
updated: 2022-02-23T19:56:33.363Z
tags: ["general-programming", "javascript"]
reading_time: 3
upvotes: 98
comments: 3
language: en
---

> ## Documentation Index
> Fetch the complete documentation index at: https://daily.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# All in one! Javascript promises…

**[Medium](https://daily.dev/sources/medium_js)** · 3 min read · 98 upvotes · 3 comments

## Summary

Javascript promises (“Can be Fulfilled | Rejected”) can be considered as the asynchronous counter part of a getter function. Javascript is a single threaded & Only one thing can happen at a time, on a single main thread. To avoid promise chaining and to write clean code, we have async & await. Async Await acts as syntactic sugar on top of promises, making asynchronous code easier to write and read.

## Full article

daily.dev links to this article rather than hosting it. Read it at the original source: <https://medium.com/dhiwise/all-in-one-javascript-promises-77b5bd7c7c61?source=rss------javascript-5>

## Community discussion

Top comments from developers on daily.dev.

**@ravisojitra** · 0 upvotes

> so great

**@papoel** · 0 upvotes

> Excellent 👌 thanks.

**@randyknight** · 0 upvotes

> Thank you for the explanation of promises in JS, it was very helpful. 😎

## Similar posts on daily.dev

- [Don’t just attend KubeCon \+ CloudNativeCon, Merge Forward your experience\!](https://daily.dev/posts/don-t-just-attend-kubecon-cloudnativecon-merge-forward-your-experience--l0rpp73x8) · CNCF · 0 upvotes · 0 comments
- [Announcing H2 2026 KCDs](https://daily.dev/posts/announcing-h2-2026-kcds-m96goajm1) · CNCF · 1 upvotes · 0 comments
- [Two months of Open Community Groups](https://daily.dev/posts/two-months-of-open-community-groups-asf52zhbs) · CNCF · 0 upvotes · 0 comments

---

Tags: [#general-programming](https://daily.dev/tags/general-programming), [#javascript](https://daily.dev/tags/javascript)

[View this post on daily.dev](https://daily.dev/posts/all-in-one-javascript-promises--j20xzbhnu)
