-
Notifications
You must be signed in to change notification settings - Fork 109
Update code to export umd, cjs, esm etc #212
Conversation
Psyched for this! |
@@ -1,4 +1,4 @@ | |||
import { composePath, composeUrl } from "./composeUrl"; |
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.
Why did you move everything inside a __tests__
folder? 🤔
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.
No, really reason, mainly it was late and I was having a feeling it was leaking into the final builds. I am happy to revisit and move them back if you want.
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.
I usually prefer my tests aside the component (otherwise people forget about these 😬), but I get the leaking part, I have the same locally 😕 (I was playing a bit with tsdx today, to give a try and see if need all this extra configuration)
Why
In the past there has been tickets raised that the library isn't straight away usable with
create-react-app
and other projects. I have created a test app at: https://github.com/weyert/restful-react-demoThis PR contains a bunch of changes at first the contained in PR #211 but then also:
rollup
-config specifically for the tools scripts namedtools.rollup.config.js
- Tools scripts end up in
lib
- Actually components end up in
dist
__tests__
rollup
-plugins