Import modules from all files in directory
Considering I have multiple ts files in a folder and all of them export the same type module. Can I import them like this?
import * as things from "./things/";
2 Replies
This is not possible with this syntax. You could read the files in the directory and use dynamic imports to load them.
Thanks, will do