Skip to content
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

Not substitue path in d.ts #10

Open
shenghu opened this issue Jul 13, 2018 · 6 comments
Open

Not substitue path in d.ts #10

shenghu opened this issue Jul 13, 2018 · 6 comments

Comments

@shenghu
Copy link

shenghu commented Jul 13, 2018

My code is something like this
dist/
src/
index.ts
hello.ts

where index.ts contains

export * from 'src/hello';

In dist/, after running tspath, index.d.ts still contains

export * from 'src/hello';
@duffman
Copy link
Owner

duffman commented Nov 14, 2018

Currently, definition files are not supported, there is a new version 2 coming very soon, this release is a very serious release which will contain support for definitions among many other frequently requested features.

@barthuijgen
Copy link

Hi @duffman, when is this release coming? We're 5 months further and you said "Very soon" I just ran into this exact same issue when trying out tspath (loving the tool by the way, great work). I cannot use it without definition file support though.

@rafamel
Copy link

rafamel commented Apr 23, 2019

@barthuijgen if it helps you, or anyone, this can be done via ttypescript + @zerollup/ts-transform-paths. Here's a working example config -note that the config extends a tsconfig.json file, which in turns extends a jsconfig.json containing the paths. Then just call ttsc instead of tsc -works as a drop-in replacement.

@barthuijgen
Copy link

Thanks @rafamel, I tried out your solution, and while it does seem to output correct files in my dist, it also produces a lot of typescript build errors of "module not found", I'm unsure which repository to submit this as an issue to. tspath sofar works the best for me, except not transforming .d.ts files :(

@ReactiioN1337
Copy link

ReactiioN1337 commented Nov 10, 2019

@duffman some news about it?

@searleser97
Copy link

any news on this ? @duffman

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants