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

89
Vistas
Documenting functions built by a Proxy get trap

In https://github.com/draber/fancy-node/blob/main/src/index.js#L242 I use the get trap of a Proxy to build function names on the fly. That works just fine, but the problem is documentation. I'd like to have IntelliSense in VS Code for instance, but I have no idea on where to start. I'd be grateful for any pointers.

about 4 years ago · Juan Pablo Isaza
1 Respuestas
Responde la pregunta

0

In case somebody comes with a similar problem in the future, I have found a solution. In my particular scenario I know the names and signatures of all "virtual", i.e. Proxy-generated functions.

A file index.d.ts with all function declarations in the same directory where index.js (the main entry point) lives solves the issue. VS code uses this file for IntelliSense but it won't appear in the bundle, so that the file size doesn't change.

about 4 years ago · Juan Pablo Isaza Denunciar
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