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

Investigate feasibility/benefit of porting project to Typescript #14

Closed
brandongregoryscott opened this issue Oct 3, 2019 · 8 comments · Fixed by #130
Closed

Investigate feasibility/benefit of porting project to Typescript #14

brandongregoryscott opened this issue Oct 3, 2019 · 8 comments · Fixed by #130
Assignees
Labels
enhancement New feature or request hacktoberfest Support hacktoberfest (not required to get credit)

Comments

@brandongregoryscott
Copy link
Contributor

Description
Investigate how much of a lift porting the project over to Typescript would be. Document any caveats or potential roadblocks, changes in development workflow, npm package publishing, etc.

@brandongregoryscott brandongregoryscott added enhancement New feature or request hacktoberfest Support hacktoberfest (not required to get credit) pregroom Pending additional details before it is ready to be worked on labels Oct 3, 2019
@wintondeshong
Copy link
Contributor

@brandongregoryscott should be entirely feasible. Believe we would ts-node to allow us to run it without an additional transpilation step. Probably better to start this sooner rather than later. Less to port :)

@wintondeshong wintondeshong self-assigned this Oct 22, 2019
@wintondeshong
Copy link
Contributor

Gonna hack on this some and see how it goes

@wintondeshong
Copy link
Contributor

Initial findings:

  • First pass port should be simple
  • Getting to strict typings will take a bit more time
  • While we can run "live" transpilation through ts-node (skipping need to keep .js artifacts), there is a noticeable delay running through ts-node -T cli.ts. So while we would use ts-node for development, we'd want to run a tsc -p when releasing new versions so there isn't any delay for end users

@wintondeshong wintondeshong removed the pregroom Pending additional details before it is ready to be worked on label Oct 22, 2019
@wintondeshong
Copy link
Contributor

After discussing internally with @Stefanie899 and @brandongregoryscott we are going in the direction of housing source files in src and adding an official build step to lib on releases.

In an ideal world where transpiling typescript was trivial, we wouldn't need to output the javascript build and could just run "live" through ts-node. Development experience will be in that ideal, but publishing new versions will be output to 'lib' where end-users will use it.

@brandongregoryscott
Copy link
Contributor Author

@wintondeshong I know you were hacking on this previously, I'd love to get us on typescript soon. Any thoughts on pushing up what you have and letting me wrap it up?

@wintondeshong
Copy link
Contributor

Sorry for missing this @brandongregoryscott -- This has been sitting here long enough that I don't feel my branch helpful. We have a much better tuned approach for TS across our projects that starting this issue from scratch is probably easier. I'm going to unassign myself for now so others can take it on.

@brandongregoryscott
Copy link
Contributor Author

No worries @wintondeshong! A lot has changed, for sure. I won't assign myself just yet, but I have been experimenting with an extended CLI and was able to get it on TS with minor hiccups over the weekend.

@brandongregoryscott
Copy link
Contributor Author

Closing this as the initial port work has been completed and merged to release/2.0.0. Will report back when it has been merged down to main

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request hacktoberfest Support hacktoberfest (not required to get credit)
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants