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

174
Visualizações
Javascript file cause React (Typescript) fail to start

I have a React project with Typescript. One day I create a javascript file in src/ and then my React app failed to start on localhost. Any explanation about this would be appriciated.
Evironment: Node 16.13.1
Step to reproduce:

git clone git@github.com:manaclan/fun-pms-frontend.git
cd fun-pms-frontend
git checkout vinhngo

Inside package.json remove:

"@types/react-facebook-login": "^4.1.4"
"react-facebook-login": "^4.1.1"

Then npm install and npm start will notify that localhost:3000 failed to connect. Removing src/setupProxy.js will make the server start as normal

about 4 years ago · Santiago Trujillo
1 Respostas
Responde à pergunta

0

That's because JavaScript is not allowed in Typescript projects, you would need to modify your Typescript config, add the following flag to to the config file

--allowJs

Depending on the module bundler you probably also have to set the output directory for the transpiled Typescript files.

about 4 years ago · Santiago Trujillo Relatório
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