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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

馃Ч Cleanup: Rewrite InputWritr to use generics and have less convoluted settings #317

Open
3 tasks done
JoshuaKGoldberg opened this issue Aug 21, 2022 · 0 comments
Open
3 tasks done
Labels
area: documentation Improvements or additions to documentation package: inputwritr status: needs investigation More research is required before we can settle on a plan. type: cleanup Improving code architecture and/or cleanliness.

Comments

@JoshuaKGoldberg
Copy link
Member

Tooling Report Checklist

  • I have tried restarting my IDE and the issue persists.
  • I have pulled the latest main branch of the repository.
  • I have searched for related issues and found none that matched my issue.

Overview

InputWritr is one of the oldest modules in this package and the design shows it. Two main issues:

  • The system of events/triggers/types and their aliases is convoluted and hard to understand
  • Many of the types use strings instead of type parameterized unions, and/or as any internally

I'd like to revisit the design from scratch to make full use of newer TypeScript features. And then also be comprehensible.

Additional Info

No response

@JoshuaKGoldberg JoshuaKGoldberg added type: cleanup Improving code architecture and/or cleanliness. package: inputwritr area: tooling Builds, infrastructure, packages, and other repository management status: needs investigation More research is required before we can settle on a plan. area: documentation Improvements or additions to documentation and removed area: tooling Builds, infrastructure, packages, and other repository management labels Aug 21, 2022
@JoshuaKGoldberg JoshuaKGoldberg changed the title 馃洜 Tooling: Rewrite InputWritr to use generics and have less convoluted settings 馃Ч Cleanup: Rewrite InputWritr to use generics and have less convoluted settings Aug 21, 2022
JoshuaKGoldberg added a commit that referenced this issue Aug 21, 2022
Cleans up InputWritr a bit by improving some of the docs and function names.

Adds partial unit test coverage
Moves alias conversion to UserWrappr, where it belongs
Renames makePipe to createPipe (I like "create" more for this)_
Removes a few unused areas of code

Filed #317 to tackle a more complete overhaul of the package long term.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: documentation Improvements or additions to documentation package: inputwritr status: needs investigation More research is required before we can settle on a plan. type: cleanup Improving code architecture and/or cleanliness.
Projects
None yet
Development

No branches or pull requests

1 participant