n3m3sis00 / phylo-react

React component library for Phylogenetic Analysis
https://n3m3sis00.github.io/phylo-react/
1 stars 1 forks source link

Make peer deps #37

Closed cmdcolin closed 3 years ago

cmdcolin commented 3 years ago

This is a couple of small modifications to the scripts

1) Makes d3, react, and react-dom peer dependencies. This is because you could otherwise have multiple copies of react. See https://stackoverflow.com/questions/43635703/what-should-be-peer-dependencies-when-creating-libs-in-webpack

2) Makes other things that are not required to be runtime dependencies into peer dependencies

3) Removes docify story because it appeared to have some unclear documentation, we might want to make sure that the docs are accurate for our components

4) Uses prebuild: npm run clean, build: babel step, and then the publish command automatically runs the build

cmdcolin commented 3 years ago

After making these changes I was able to do https://github.com/cmdcolin/phylo-react-demo

This dynamically fetches a phylogeny from the Ensembl API

Live demo here https://cmdcolin.github.io/phylo-react-demo/

n3m3sis00 commented 3 years ago

@cmdcolin Thanks for the Pull Request :)

n3m3sis00 commented 3 years ago

Removes docify story because it appeared to have some unclear documentation, we might want to make sure that the docs are accurate for our components

Yes, it was just a way to create docs for different components by passing description(string), props(array), and component itself.

we can figure out a different way :)

n3m3sis00 commented 3 years ago

Live demo here https://cmdcolin.github.io/phylo-react-demo/

It looks awesome :smiley: