-
-
Notifications
You must be signed in to change notification settings - Fork 239
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
Enables custom resolver only if they're used in incremental mode #260
Conversation
Note that it won't fix it for people w/ custom resolvers, but at the moment that's only PnP users and that probably can be considered a caveat. |
Opened an issue on the TS repo to discuss more long-term fixes: microsoft/TypeScript#31056 |
Hey @arcanis, I've read this through a bunch of times but I think I'm not quite following it. Or I may be but I'm not certain I understand correctly. If it's cool with you I'll make a bunch of statements and you can agree / set me straight as necessary:
Regarding tests, I think integration tests are the way to go here. Essentially, if we have a test something like this: https://github.com/Realytics/fork-ts-checker-webpack-plugin/blob/dfd8933f23da7ca72aa3a864e5811725146323d4/test/integration/index.spec.js#L122 Which detects an error in an alias path module we should be good to go. And obviously we'd only run this against the non-incremental API |
No it's less serious than this:
Basically the options are still not forwarded properly when having custom resolvers w/ the incremental API, but the consequences now only affect people that use custom resolvers. |
Should be good now. I've still put the test in the two modes but marked it as skipped in incremental mode, as it's something that should work in the future. |
Great! This should go out with https://github.com/Realytics/fork-ts-checker-webpack-plugin/releases/tag/v1.1.1 BTW @piotr-oles is switching the repo over to use semantic releases and so I think this may be the last release to go out this way! |
🎉 This PR is included in version 1.2.0-beta.3 🎉 The release is available on: Your semantic-release bot 📦🚀 |
The thing I'm going to miss now we're in semantic release land is the ability to raise mini PRs and ship releases from my phone. I'm always going to need a keyboard and terminal from now I guess... Still.... Emoji in commits 😎 |
Why do you need a terminal? :) You can create a pull request and type proper commit message and semantic-release will do the work for you. Am I missing a point? |
Maybe you're right... I guess how strict is "proper commit message"? Looking at a sample commit:
Do I need the " 🐛"? Because I'm going to struggle finding that on my phone keyboard 😁 Maybe it's something I'll learn over time; but doesn't semantic release recommend using their That made me think "wow this is clearly easy to get wrong; we're going to need to rely if That's not your experience? If not, great! |
Haha, you don't need emoji, don't worry - just |
… manually after merging Revert "Enables custom resolver only if they're used in incremental mode (TypeStrong#260)" This reverts commit 3990a13. Revert "Adds support for custom resolvers to CompilerHost (TypeStrong#250) - fixes TypeStrong#181" This reverts commit dfd8933.
This reverts commit 9db85d7.
This diff only adds the custom
resolveModuleNames
wrapper if the custom resolution is really used. It theoretically shouldn't be needed (we should be able to implement the default resolution), but there's a problem in TS with the watch system.Since it's only about the native TS watch system, I've only made the change in
CompilerHost
(not inIncrementalWatcher
).Tests are a bit more funky since it requires a plugin. Thoughts?