Skip to content

Commit 92a78ea

Browse files
authored
Merge pull request rescript-lang#424 from jamespwilliams/master
Fix grammatical errors in pipe.mdx, and make some subjective wording tweaks
2 parents 7983f42 + 26ed22b commit 92a78ea

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

pages/docs/manual/latest/pipe.mdx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -67,17 +67,17 @@ a(one, two, three);
6767

6868
This also works with labeled arguments.
6969

70-
Pipes are used to emulate object-oriented programming, e.g. what's `myStudent.getName` in other languages like Java would be `myStudent->getName` in ReScript (aka `getName(myStudent)`). This allows us to have the readability of the good parts of OOP without its downside of dragging in a huge class system just to call a function on a piece of data.
70+
Pipes are used to emulate object-oriented programming. For example, `myStudent.getName` in other languages like Java would be `myStudent->getName` in ReScript (equivalent to `getName(myStudent)`). This allows us to have the readability of OOP without the downside of dragging in a huge class system just to call a function on a piece of data.
7171

7272
## Tips & Tricks
7373

74-
Do **not** to abuse pipes; they're a means to an end. Inexperienced engineers sometimes shape a library's API to take advantage of the pipe. This is backward.
74+
Do **not** abuse pipes; they're a means to an end. Inexperienced engineers sometimes shape a library's API to take advantage of the pipe. This is backwards.
7575

7676
## JS Method Chaining
7777

7878
_This section requires understanding of [our binding API](bind-to-js-function.md#object-method)_.
7979

80-
JavaScript's APIs are often attached to objects, and often chainable, like so:
80+
JavaScript's APIs are often attached to objects, and are often chainable, like so:
8181

8282
```js
8383
const result = [1, 2, 3].map(a => a + 1).filter(a => a % 2 === 0);

0 commit comments

Comments
 (0)