Join GitHub today
GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.Sign up
Convert project to Typescript and add es2015 build target #672
This PR tries to fix #644, which happens when native classes are used via
Updated implementation notes
Original implementation notes (babel)
Babel is not well suited to transform to a specific language level, so transforming to ~es2015 is kind of hacky in this implementation. The best solution would be to instead compile this library as
If converting to
This is AWESOME!! and I'm definitely down for porting to TypeScript--it's long overdue tbh Did you volunteer? If you don't have cycles, I should be able to do it soon. If it's easier for a first pass, feel free to skip strict options like no implicit any, non-nullables, etc and I can come in and fix it if there are cases where we're doing things that might require heavy refactoring to make type safe/not awkward.
Thank you!! <3
Edit: re-read and it does indeed sound like you volunteered. Thank you!
csvn left a comment •
@jayphelps I've made a first iteration that seems to be working as it should.
I'll try to respond in a timely manner to any questions
Tests are passing again, and I think I've addressed your comments. I decided not to change all the tests that breaks the typing. Some are intentionally verifying that error is thrown if epic does not return a stream. Some tests are just simpler of they do not send exact correct types to an epic. I can of course adjust this if you think that's appropriate.
All LGTM. If anyone has objections or changes, lmk, but I'm gonna merge for now.
Won't be releasing this immediately, as I'd like to do this under 2.0.0 major version bump and there are some other things that are almost ready for that.
If anyone is interested in alpha testing a build of this, I can publish as a special tag to npm, just lmk. Otherwise I'll chime in when I've done that anyway, probably in a couple days.