Translation for Advanced Guides/Refs and the DOM#13
Merged
taehwanno merged 4 commits intoreactjs:masterfrom Feb 28, 2019
ENvironmentSet:refs-and-the-dom
Merged
Translation for Advanced Guides/Refs and the DOM#13taehwanno merged 4 commits intoreactjs:masterfrom ENvironmentSet:refs-and-the-dom
taehwanno merged 4 commits intoreactjs:masterfrom
ENvironmentSet:refs-and-the-dom
Conversation
taggon
reviewed
Feb 10, 2019
Contributor
Author
|
리뷰 감사합니다. 수정하고 PR 업데이트 하도록 하겠습니다. |
ENvironmentSet
commented
Feb 10, 2019
ENvironmentSet
commented
Feb 10, 2019
content/docs/refs-and-the-dom.md
Outdated
| ### 콜백 ref에 관한 주의사항 {#caveats-with-callback-refs} | ||
|
|
||
| If the `ref` callback is defined as an inline function, it will get called twice during updates, first with `null` and then again with the DOM element. This is because a new instance of the function is created with each render, so React needs to clear the old ref and set up the new one. You can avoid this by defining the `ref` callback as a bound method on the class, but note that it shouldn't matter in most cases. | ||
| 만약 `ref` 콜백이 인라인 함수로 선언되있다면 `ref` 콜백은 업데이트 과정 중에 처음에는 `null`로, 그 다음에는 DOM 엘리먼트로, 총 두 번 호출됩니다. 이러한 현상은 매 랜더링마다 `ref` 콜백의 새 인스턴스가 생성되므로 React가 이전에 사용된 ref을 제거하고 새 ref을 설정해야 하기 때문에 일어납니다. 이러한 현상은 `ref` 콜백을 클래스에 바인딩된 메서드로 선언함으로서 해결할 수 있습니다. 하지만 많은 경우 이러한 현상은 문제가 되지 않는다는 점을 기억하세요. |
Contributor
Author
There was a problem hiding this comment.
이 부분 번역이 매끄럽게 되지 않은 것 처럼 보입니다. 더 나은 번역이 있다면 추천 부탁드립니다.
Member
There was a problem hiding this comment.
만약은선언되있다면로 인해 삭제해도 될 것 같아요.랜더링->렌더링ref을 제거하고 새 ref을->ref를 제거하고 새 ref를ref는레퍼런스로 읽고 있어요 (Translate Glossary)선언함으로서->선언함으로써
ENvironmentSet
commented
Feb 10, 2019
ENvironmentSet
commented
Feb 10, 2019
This was referenced Feb 11, 2019
Closed
taehwanno
reviewed
Feb 28, 2019
Member
taehwanno
left a comment
There was a problem hiding this comment.
피드백이 조금 느렸네요. 빠르게 드릴 수 있도록 노력할게요 :)
content/docs/refs-and-the-dom.md
Outdated
| ### 콜백 ref에 관한 주의사항 {#caveats-with-callback-refs} | ||
|
|
||
| If the `ref` callback is defined as an inline function, it will get called twice during updates, first with `null` and then again with the DOM element. This is because a new instance of the function is created with each render, so React needs to clear the old ref and set up the new one. You can avoid this by defining the `ref` callback as a bound method on the class, but note that it shouldn't matter in most cases. | ||
| 만약 `ref` 콜백이 인라인 함수로 선언되있다면 `ref` 콜백은 업데이트 과정 중에 처음에는 `null`로, 그 다음에는 DOM 엘리먼트로, 총 두 번 호출됩니다. 이러한 현상은 매 랜더링마다 `ref` 콜백의 새 인스턴스가 생성되므로 React가 이전에 사용된 ref을 제거하고 새 ref을 설정해야 하기 때문에 일어납니다. 이러한 현상은 `ref` 콜백을 클래스에 바인딩된 메서드로 선언함으로서 해결할 수 있습니다. 하지만 많은 경우 이러한 현상은 문제가 되지 않는다는 점을 기억하세요. |
Member
There was a problem hiding this comment.
만약은선언되있다면로 인해 삭제해도 될 것 같아요.랜더링->렌더링ref을 제거하고 새 ref을->ref를 제거하고 새 ref를ref는레퍼런스로 읽고 있어요 (Translate Glossary)선언함으로서->선언함으로써
content/docs/refs-and-the-dom.md
Outdated
| - **You may not use the `ref` attribute on function components** because they don't have instances. | ||
| - `ref` 어트리뷰트가 HTML 엘리먼트에 쓰였다면, 생성자에서 `React.createRef()`으로 생성된 `ref`은 자신을 전달받은 DOM 엘리먼트를 `current` 프로퍼티의 값으로서 받습니다. | ||
| - `ref` 어트리뷰트가 커스텀 클래스 컴포넌트에 쓰였다면, `ref` 객체는 마운트된 컴포넌트의 인스턴스를 `current` 프로퍼티의 값으로서 받습니다. | ||
| - **함수형 컴포넌트는 인스턴스가 없기 때문에 함수형 컴포넌트에 ref 어트리뷰트를 사용할 수 없습니다**. |
Member
There was a problem hiding this comment.
변경 누락된 것 같아요. 함수형 컴포넌트 -> 함수 컴포넌트로 수정 부탁드려요. (2개의 함수형이 수정돼야 합니다.)
|
Deploy preview for ko-reactjs-org ready! Built with commit a6b8d8d |
taehwanno
previously approved these changes
Feb 28, 2019
Member
|
a6b8d8d |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
some weird translations may be included. needs your feedbacks :))