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

312
Visualizações
webpack: ReferenceError: React is not defined

Got this when loading a component: ReferenceError: React is not defined

Tried this solution here: Uncaught ReferenceError: React is not defined

added following to webpack.config.json

externals: {'react': 'React' },

but then I got following error. So what is wrong?

external "React":1 Uncaught ReferenceError: React is not defined
    at 63804 (external "React":1:18)
    at n (bootstrap:19:32)
    at shortcode32.js?ver=2.0.37:2:317202
    at shortcode32.js?ver=2.0.37:2:385167

What files / code should I show to provide you with more info?


Error is raised here:

react-dom.production.min.js:194 ReferenceError: React is not defined
    at R (LoginAndRegistrationL.tsx:2:2)
    at Yi (react-dom.production.min.js:145:98)

in LoginAndRegistrationL.tsx funny, I removed everything from LoginAndRegistrationL.tsx, only a raw componenet I left:

export default function LoginAndRegistrationL(props: {}) {
    return <div></div>
}

Why it raise the error?

This componenet will be visible when a button press happens. Why other component does not raise "React" error, but this yes.

about 4 years ago · Santiago Gelvez
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