Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

157
Visualizações
When exporting components (e.g. React), how to keep track of "which components are importing this component"?

In upstream components like App.js, I can identify the list of child components being imported:

import SorryForDumbQuestion from './SorryForDumbQuestion';

But I'm struggling the other way around. When I look inside SorryForDumbQuestion.js there is an export code saying "I want to export this component" but it doesn't tell me where. Rightfully so, especially for reusable components. But in reality I want to know the consumers, and I don't know the best way to do that.

Best may be subjective as there are many ways of doing this, but is there an established good-practice way? For example I could:

  1. comment them when exporting
export default SorryForDumbExamples;
// to be used by App.js
  1. rely on IDE

  2. create documentation

  3. remember this in my brain

about 4 years ago · Juan Pablo Isaza
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda