Skip to content
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

Initial useEffect translation #682

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

renato-bohler
Copy link
Contributor

This PR contains the initial translation for the useEffect page.

@github-actions
Copy link

github-actions bot commented May 4, 2023

Size changes

📦 Next.js Bundle Analysis for react-dev

This analysis was generated by the Next.js Bundle Analysis action. 🤖

This PR introduced no changes to the JavaScript bundle! 🙌

Comment on lines +1864 to +1866
* Se seu Effect não foi causado por uma interação (como um clique), o React deixará o navegador **pintar a tela atualizada antes de executar seu Effect.** Caso seu Effect esteja fazendo algo visual (por exemplo, posicionando um tooltip) e o atraso for perceptível (causando, por exemplo, tremulações), substitua `useEffect` por [`useLayoutEffect`.](/reference/react/useLayoutEffect)

* Mesmo que seu Effect tenha sido causado por uma interação (como um clique), **o navegador pode repintar a tela antes de processar atualizações de state dentro de seu Effect.** Normalmente, é isto que você quer. No entanto, se você precisar impedir o navegador de repintar a tela, você precisará substituir `useEffect` por [`useLayoutEffect`.](/reference/react/useLayoutEffect)
Copy link
Member

@jhonmike jhonmike May 10, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✂️ esse trecho não esta mais na versão original em ingles e deve ser apagado, ou vc precisa atualizar sua branch com a main para verificar se esta correto

@jhonmike jhonmike added the needs review A pull request ready to be reviewed label May 10, 2023
@jhonmike jhonmike added needs author response Changes requested needing author's input and removed needs review A pull request ready to be reviewed labels May 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
needs author response Changes requested needing author's input
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants