-
Notifications
You must be signed in to change notification settings - Fork 19
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
Issue migrating to TypeScript #114
Comments
What issue does TypeScript solve here? The app and code is stable for years and well tested. |
I'm trying to upgrade As The end result should be the same. There is no change on the end user point of view. It's just a dependencies upgrade. And the tests remains the same which means nothing that was tested in the current version will break in the next version. I hope it helps to understand the idea of this migration. I don't want to enforce it. I can still migrate my own fork if migrating to TypeScript is a no go. |
I checked the https://github.com/yeoman/generator-generator source code and I don't see any reference to to this package there. If this package is to be used from TypeScript code a type definition file can be created. I don't see a point in rewriting this app and make it much more complicated with additional tools for compilation when it is working fine. |
Just to let you know: Regarding TypeScript in the Yeoman generator eco system. Chhers, Michael |
So it's for these three lines https://github.com/yeoman/generator-node/blob/25d1ca4ea2122ce08b88398848e6df41f54cbe1a/generators/app/index.js#L363-L366 That can be done by type definition and not by requiring the whole project to be change to a different toolset. |
@jozefizso I completely understand your point and in that case I would suggest I will just maintain a TypeScript fork so that I don't disturb your work. @mischah I will then update the dependencies to point to a package like And I'll see if I can move this issue to my fork. Otherwise I'll just copy it into mine. Is that fine for everybody ? Thanks for your inputs. |
A fork doesn’t make sense in this case. Since This project is maintained. Why don’t you use this as it is? And create a PR adding type definitions in case @jozefizso will accept to merge this. What’s your pain with having a JavaScript dependency in a TypeScript Repo? |
I will accept TypeScript type definitions for this repo. The change to TypeScript tooling is our of question. |
I am really sorry. I didn't understand that having the types definition would actually solve the issue. Thanks for the explaination I will then add the types definitions and open a PR for this. Thanks for the help and have both a nice weekend. |
Hi. I'm trying to migrate this generator to TypeScript. I get the following error when trying to migrate this generator to TypeScript:
Building the generator with
npm run build
works. And the built package is executed as before. I'm just encountering an error in the tests. There might be an issue in the Jest configuration. I managed to fix it in a project using mocha but I'm not a Jest expert.The branch to test the problem is there: https://github.com/groovytron/generator-license/tree/migrate-to-typescript
Maybe @mischah could give us a hand on this.
Thanks for your help.
The text was updated successfully, but these errors were encountered: