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

configFile ignored if TS_NODE_PROJECT is set #17

Open
phryneas opened this issue May 22, 2018 · 2 comments
Open

configFile ignored if TS_NODE_PROJECT is set #17

phryneas opened this issue May 22, 2018 · 2 comments

Comments

@phryneas
Copy link

phryneas commented May 22, 2018

Hi :)

I have an extra tsconfig.json for my webpack configuration that is different from the tsconfig.json that should be used by tsconfig-paths-webpack-plugin.

The way to pass a different config to webpack is by setting TS_NODE_PROJECT - unfortunately that leads to tsconfig-paths-webpack-plugin ignoring the configFile option in favor of the one in the environment variable :/

I guess that the problem itself is somewhere in https://github.com/dividab/tsconfig-paths , but I think it is more a bug with tsconfig-paths-webpack-plugin so I was not really sure where to post this issue, but as you are the maintainer of both projects, I guess this is fine ;)

@naruaway
Copy link

naruaway commented Aug 3, 2018

I also encountered the same problem.
Although putting delete process.env.TS_NODE_PROJECT at the top of webpack.config.ts worked as workaround for me, I think configFile should not be ignored silently :)

@VictorQueiroz
Copy link

delete process.env.TS_NODE_PROJECT seems very hacky to me. It seems to be an issue here. Not sure why. Maybe the author's preference. >> https://github.com/dividab/tsconfig-paths/blob/master/src/tsconfig-loader.ts#L37

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

3 participants