---
title: "Discussion on \"Generators In JavaScript\" | Hashnode"
description: "Discussion on \"Generators In JavaScript\". A function can only return a single value. Generators `function*` helps to return more than one value, one after another, and on-demand in javascript."
url: "https://hashnode.com/posts/generators-in-javascript/61530cec9c8bfd08f5ba70c7"
---

[Feed](https://hashnode.com/feed) /

Discussion

# [Generators In JavaScript](https://blog.oluwasetemi.dev/generators-in-javascript?utm_source=hashnode&utm_medium=feed)

A function can only return a single value. Generators \`function\*\` helps to return more than one value, one after another, and on-demand in javascript.

Sep 28, 2021 · 9 min read · blog.oluwasetemi.dev  
Updated Sep 29, 2021  
Read the article

-   [#javascript](https://hashnode.com/tag/javascript)
-   [#typescript](https://hashnode.com/tag/typescript)
-   [#tutorial](https://hashnode.com/tag/tutorial)

## Written by

[Olúwásetèmi Ojo](https://hashnode.com/@setemiojo)

@setemiojo · Osun state, Nigeria

  
[View profile](https://hashnode.com/@setemiojo)

Developer on a journey. I'm a Developer. I make all sort of stuff with Typescript, JavaScript, React, Nodejs. You can find my work on GitHub

I'm Oluwasetemi 🇳🇬, It is pronounced SE + TE(Not TI) + ME. Most people call me Ojo. Other variant of my name is Temi or Setemi or Stephen. Address me with anyone that is easy for you. I'm a web developer, who is passionate about the stuffs I build. I am from Nigeria 🇳🇬, I love to work with JavaScript, Typescript Reactjs, Nodejs and GraphQL. I prefer to solve problems. I have keen interest in roles around Frontend Engineering, Backend Engineering, Developer Education, Developer Relations or Developer Experience and any Full-Stack roles. I sometimes teach programming and web development related courses to entry level developers. I focus on all the stuffs that will make the difference and make learning interesting. I have a special way of making complex concept simple and easy to grasp.

## Responses

Markdown supported · ⌘↵ to post

No responses yet.
