You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi! I'm working on some changes in Storybook, and I've come across a problem. I have an entry file that is only performing a function call, without any exports. When I run it through tsup, with the dts option set, I get an empty declaration file. Typescript itself puts export {} in the .d.ts file, so that it is still treated as a module and avoids errors in other modules that import it (for side-effects, for example).
Hi! I'm working on some changes in Storybook, and I've come across a problem. I have an entry file that is only performing a function call, without any exports. When I run it through tsup, with the
dts
option set, I get an empty declaration file. Typescript itself putsexport {}
in the .d.ts file, so that it is still treated as a module and avoids errors in other modules that import it (for side-effects, for example).Here's an example typescript playground which shows the .d.ts being created as
export {}
: https://www.typescriptlang.org/play?target=7&module=1&isolatedModules=true&allowSyntheticDefaultImports=false&ts=4.8.4#code/JYWwDg9gTgLgBGAhjAFnAZlCI4HImq4DcAsAFDnoCuAdgMYzAQ1xQCmA5sAM4xtQAKAJRwA3uThw6zbhAA2bAHRyIHAbgAmEOIjipgNDriGkyAX3Ll2XXv2GmgABut, when I create such a file with tsup and compile it, I get an empty file.
Please let me know if I can do anything to help troubleshoot or solve this.
The text was updated successfully, but these errors were encountered: