I have been creating various node packages utilizing ES Modules. Within these packages, some modules are meant to be utilized externally by other packages, while certain module exports are intended for internal use only within my own package.
From my understanding, there is currently no built-in method to designate certain modules as strictly internal in ES modules. Are there any established best practices or guidelines that developers follow when developing node packages to discourage the utilization of internally designated modules?
The need for this arises because my packages are coded in TypeScript and the automatic generation of declaration files by TypeScript includes exports for modules that are intended for internal use only.