Uh oh!
There was an error while loading. Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork 391
Sync with reactjs.org @ 022c1b2f#169
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Uh oh!
There was an error while loading. Please reload this page.
Changes from all commits
7fd8a8de3f43f5cd7bfe7f1e8fa45b6abc9f5ccd7e7abe468aaefe69d4f7a2c671674518c7c0f2819a0f0569c210948bf5e7a4bf6022c1b22284e2a2e8463aFile filter
Filter by extension
Conversations
Uh oh!
There was an error while loading. Please reload this page.
Jump to
Uh oh!
There was an error while loading. Please reload this page.
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -14,7 +14,7 @@ const EnhancedComponent = higherOrderComponent(WrappedComponent); | ||
| Whereas a component transforms props into UI, a higher-order component transforms a component into another component. | ||
| HOCs are common in third-party React libraries, such as Redux's [`connect`](https://github.com/reactjs/react-redux/blob/master/docs/api/connect.md#connectmapstatetoprops-mapdispatchtoprops-mergeprops-options) and Relay's [`createFragmentContainer`](http://facebook.github.io/relay/docs/en/fragment-container.html). | ||
| HOCs are common in third-party React libraries, such as Redux's [`connect`](https://github.com/reduxjs/react-redux/blob/master/docs/api/connect.md#connect) and Relay's [`createFragmentContainer`](http://facebook.github.io/relay/docs/en/fragment-container.html). | ||
Contributor There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Should be fixed in #167 Contributor There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Уже исправлено. | ||
| In this document, we'll discuss why higher-order components are useful, and how to write your own. | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -216,10 +216,18 @@ Congrats! You've installed the latest version of TypeScript into your project. I | ||
| ``` | ||
| ### Configuring the TypeScript Compiler {#configuring-the-typescript-compiler} | ||
| The compiler is of no help to us until we tell it what to do. In TypeScript, these rules are defined in a special file called `tsconfig.json`. To generate this file run: | ||
| The compiler is of no help to us until we tell it what to do. In TypeScript, these rules are defined in a special file called `tsconfig.json`. To generate this file: | ||
Contributor There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Should be fixed in #166 | ||
| If you use [Yarn](https://yarnpkg.com/), run: | ||
| ```bash | ||
| yarn run tsc --init | ||
| ``` | ||
| If you use [npm](https://www.npmjs.com/), run: | ||
| ```bash | ||
| tsc --init | ||
| npx tsc --init | ||
| ``` | ||
| Looking at the now generated `tsconfig.json`, you can see that there are many options you can use to configure the compiler. For a detailed description of all the options, check [here](https://www.typescriptlang.org/docs/handbook/tsconfig-json.html). | ||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should be fixed in #97
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Предложено исправление.