-
Notifications
You must be signed in to change notification settings - Fork 11
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
typescript 4.3 support #544
Conversation
tsickle fixed the issue with the package.json file so it's all good to go now with tsickle version 0.43.0 |
Much appreciated! I will try to wrap my head around the recent changes of tsickle and review it. It's disappointing that they haven't improved in terms of module- I guess |
Hi, the change seemed mostly fine, I made a few quick changes and squash-merged with the master (I didn't know that your account is not displayed in commit log if I do this).
|
Yeah I figured the yarn/npm thing would come up. I learned about yarn vs npm over the last week or so, but before that I was struggling with the yarn side, and only npm was working for me, but of course it put it's package-lock file there. I'll see if I can get a reproducible build for the issue about those dependencies that seem to be missing causing issues with the |
Well, I just wanted to make sure I mention every change and its reason, what package manager to use is a very marginal issue I guess. While waiting for tsickle release, my attention was slowly slipping over to other tasks. Thank you for bring this up and providing & testing necessary changes! Also now tscc 0.7.0 with typescript 4.3.2 is live in NPM. |
That's awesome, thank you! |
So I got tscc to work with TS 4.3 now that tsickle supports it, but there's gray areas that I'm not 100% about.
First thing, it seems like tsickle has an issue installing on version 0.40.0 from npm where the package.json points to the wrong dir for its own files. I made an issue with them about that angular/tsickle#1272. That's what the patch file in this commit does.
Second is with the
const sf = <SourceFileWithInternalAPIs>this.host.getSourceFile(fileName);
line. This seems to be related this issue #464. In my own environment, I've jst been skipping the next actions if that line returns something falsey. I've not personally experienced any cons from that, but it feels like maybe not the right solution,Lastly, with the
const transformerHost: tsickle.TsickleHost = {
line, it seems like this version of tsickle requires a new function as part of thetsickle.TsickleHost
interface, calledrootDirsRelative
that takes a filename and returns a string. I couldn't find anything about what specifically this does, so I just wrote it to return what was passed to it and my compiled code seems to be working correctly, but again, not sure that's the right solution.