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

280
Vistas
socket.io angular-cli cannot resolve 'socket.io-client/package'

I am working on a project that is using 1.0 of angular-cli and I am trying to include socket.io into that project. However, I am faced with the following errors and I am not sure how to get around them.

Error

Module not found: Error: Can't resolve 'socket.io-client/package'

There is a warning before this error is shown referring to an unexpected token from a socket.io file namely socket.io.js.map. When I look at this file it appears to be a JSON file.

Warning for socket.io.js.map

Module parse failed: D:\madlink-test-app\madlink-dongle-app-two\node_modules\socket.io-client\dist\socket.io.js.map Unexpected token (1:10) You may need an appropriate loader to handle this file type.

According to this question it seems that I need json-loader, but from what I can tell this is included automatically when using angular-cli. Any advice that is offered for this problem would be greatly appreciated.

angular-cli version: 1.0.0

tsconfig.app.json

{
  "extends": "../tsconfig.json",
  "compilerOptions": {
    "outDir": "../out-tsc/app",
    "module": "es2015",
    "baseUrl": "",
    "types": []
  },
  "exclude": [
    "test.ts",
    "**/*.spec.ts"
  ]
}
over 4 years ago · Santiago Trujillo
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