aseemk / requireDir

Node.js helper to require() directories.
MIT License
484 stars 60 forks source link

Is there a way to get this to play nicely with Intellisense/JSDocs? #64

Closed seanohue closed 3 years ago

seanohue commented 3 years ago

Howdy,

I've been using require-dir indirectly via the Ranvier MUD project. The project has really nice source documentation which works as expected when dealing with the core repository. However, once you pull the core engine into another project with require('ranvier');, any Intellisense hinting with the JSDocs seems to be broken by the use of require-dir to pull in the source files and modularize it.

Is there a known way to fix this by configuring VSCode or otherwise setting up the use of require-dir differently?

yocontra commented 3 years ago

@seanohue It is a limitation of the intellisense that it isn't able to dynamically resolve the source code - it is probably parsing the files and looking for exports/imports and following them. I don't think there is anything we could really do about it from this package - it would be a change needed in VSCode and how they resolve source files.