Tradeshift / tradeshift-ui

Tradeshift UI is a framework-agnostic JavaScript library to help Tradeshift App developers to create cohesive user experiences and to provide reusable UI components.
https://ui.tradeshift.com
Other
33 stars 44 forks source link

Third-party usage via CommonJS #75

Closed zdlm closed 6 years ago

zdlm commented 7 years ago

As a third-party developer, I would like to include the UI components in my project as a CommonJS module. This lets it work like the rest of the libraries I'm including, so I don't have to worry about loading and I can include it in my minification process.

It's only important that I can require the module via CommonJS, not that it's actually built with CommonJS, so the easiest solution is probably a wrapper like https://github.com/umdjs/umd/blob/master/commonjsStrict.js

It also needs a solution for the CSS, probably just having it in a file by itself, which can also be loaded as a module by setting up my project correctly.

We could also consider publishing it as a npm module.

https://github.com/Tradeshift/Client-Runtime/issues/151

wiredearp commented 6 years ago

Superseded by #159: Miniumum viable NPM module.