Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

157
Vistas
adding javascript file to react

I want to use javascript files in react js, I saw many answers where they told to add script src in index.html in this way :

<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
    <meta name="theme-color" content="#000000">
    
    <link rel="manifest" href="%PUBLIC_URL%/manifest.json">
    <link rel="shortcut icon" href="%PUBLIC_URL%/favicon.ico">
    
  <title>React App</title>
  <script src="../src/app.js"></script>
  <script src="../src/helper.js"></script>
  <script src="../src/sort-algorthms.js"></script>
</head>

<body>
    
    <div id="root"></div>
    
</body>

</html>

but this is not working, please anyone help . even tried this - https://betterprogramming.pub/4-ways-of-adding-external-js-files-in-reactjs-823f85de3668

here is link to sandbox : https://codesandbox.io/s/trail-minipro-rxjz9?file=/public/index.html

about 4 years ago · Juan Pablo Isaza
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda