Skip to content

Commit 671c4d4

Browse files
authored
Update article.md
"returns the result outside" -> "returns the result to the outside"
1 parent 4d0ceef commit 671c4d4

File tree

1 file changed

+1
-1
lines changed
  • 1-js/12-generators-iterators/1-generators

1 file changed

+1
-1
lines changed

1-js/12-generators-iterators/1-generators/article.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -318,7 +318,7 @@ A generator composition is a natural way to insert a flow of one generator into
318318

319319
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.
320320

321-
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.
321+
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.
322322

323323
To do so, we should call `generator.next(arg)`, with an argument. That argument becomes the result of `yield`.
324324

0 commit comments

Comments
 (0)