New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Inlined imports do not contain import
statement from dependencies
#199
Comments
It appears this is happening because of these lines: dts-bundle-generator/src/bundle-generator.ts Lines 776 to 778 in 9676b66
Even though the declaration will eventually be inlined, it's still considered a part of the external lib |
@nsamsonov have you tried a previous versions? I guess it could be broken in one of the recent versions... |
the earliest I tried was 5.0.0 and it still didn't work |
@nsamsonov got it, thanks! I'll try to fix soon. |
@nsamsonov the fix has been published in https://github.com/timocov/dts-bundle-generator/releases/tag/v6.9.0 |
thanks a lot, it works great! |
Bug report
I have my file and two libraries (
libA
andlibB
).libA
imports some stuff fromlibB
. I wantlibA
to be inlined, while keeping import statements fromlibB
.Input code
myFile.ts
node_modules/libA/index.d.ts
node_modules/libB/index.d.ts
Expected output
Actual output
Additional context
The import is generated using
dts-bundle-generator --external-inlines=libA myFile.ts
Since the import statement is missing, the generated code is invalid. Adding
--external-inlines=libB
correctly inlineslibB
, but this is undesired behavior. Adding--external-imports=libB
has no effect.The text was updated successfully, but these errors were encountered: