-
Notifications
You must be signed in to change notification settings - Fork 28
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
build: rewrite imports from lib to es6 in es6 output #50
Conversation
@larskinn Awesome! Thanks for the contribution! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey, there! @larskinn, thanks a lot for your contribution! I think this PR is good to go, everything works as expected.
That's good to hear! @sutarmin @raveclassic One of you folks will have to merge, at your convenience 😃 |
Sure, I just want to find out why our CI integration is broken. I hope we can wait with the merge for just couple of days at most. |
Of course, no problem. |
PR build passed. I don't know how to trigger branch build without additional commits, but PR build is enough. |
Any chance of publishing a new release soon-ish @raveclassic ? |
@larskinn Oops, sorry, this slipped my mind. Just a moment. |
@larskinn Done. |
Closes #46
Closes #49
Changes
postbuild
step andtsconfig.es6.json
change from gcanti/fp-ts-rxjs@f35c926io-ts-types
had to be updated. Thees6
folder was added in version 0.5.4.src/remote-data-io.ts
, an import had to be changed to allowimport-path-rewrite
to rewrite it.Testing
I tested this on a fairly large codebase, by rewriting code that used used
Either
and thefp-ts/es6/...
imports to useRemoteData
imported from@devexperts/remote-data-ts/es6/remote-data
, and it worked well.webpack-bundle-analyzer
indicates that onlyes6
parts are bundled, and as far as I can tell only the modules that are in use are included (both fromfp-ts
andremote-data-ts
)I did not test the
remote-data-io
andremote-data-t
parts of the library, as I am not familiar withio-ts
and monad transformers. But I inspected the generated .js and .d.ts in/dist
and/es6
. The output looks correct, and all the imports resolve correctly.Let me know if you have any better ideas for testing this change!