From 671c4d41eeb43f822210dfd3e815fdcdb7f271bf Mon Sep 17 00:00:00 2001 From: Peter Roche <46547072+paroche@users.noreply.github.com> Date: Thu, 6 Feb 2020 22:15:48 -0700 Subject: [PATCH] Update article.md "returns the result outside" -> "returns the result to the outside" --- 1-js/12-generators-iterators/1-generators/article.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/1-js/12-generators-iterators/1-generators/article.md b/1-js/12-generators-iterators/1-generators/article.md index 6fe58729..e77ceb66 100644 --- a/1-js/12-generators-iterators/1-generators/article.md +++ b/1-js/12-generators-iterators/1-generators/article.md @@ -318,7 +318,7 @@ A generator composition is a natural way to insert a flow of one generator into Until this moment, generators were similar to iterable objects, with a special syntax to generate values. But in fact they are much more powerful and flexible. -That's because `yield` is a two-way street: it not only returns the result outside, but also can pass the value inside the generator. +That's because `yield` is a two-way street: it not only returns the result to the outside, but also can pass the value inside the generator. To do so, we should call `generator.next(arg)`, with an argument. That argument becomes the result of `yield`.