Closed jaronheard closed 4 years ago
I've added stories for the ui-docs
and ui-charts
packages. One really exciting opportunity with the new Storybook MDX format is being able to mix stories and documentation. I translated the data visualization guidelines that the Data Visualization platform team from the 2019 Hack Oregon season put together into mdx format with embedded interactive stories. I can also imagine a tool that allows users to view their data as many different types of charts -- it would actually be very straightforward to put together!
Phew! I think that this PR is ready for final review.
Since the tests of CSF and Chromatic were successful, this PR continues into implementation
yarn storybook
command updatedThe one exception is that ui-maps
hasn't been converted -- I'd like to make that a follow-up issue. It also disables automatic publishing of the old Storybook. Once ui-maps
is converted, we can update all of the links to hackoregon.github.io to the new Storybook.
I'm interested in some fresh eyes, and comparing the usability of this updated approach to our old approach
This PR upgrades Storybook 5 -> 6, and goes through the process of converting the ui-core package to use the new Component Story Format. Besides having a great acronym, the Component Story Format enables really nice automatically generated docs, can link up with more automated testing and tools, and is much cleaner than the previous
storiesOf
notation.It also sets up a configuration for Chromatic, which is an advanced deploy preview and visual testing tool for Storybook. My plan would be to set it up on CI so that we get a preview on each PR.
Feedback, please!
I'd like feedback in a few areas.
✨Check it out!✨
Notes
prefer-default-export
).displayname
to components that were missing it.)Screenshots
Docs
The new controls view
Knobs have been replaced with controls. The type of control is inferred from the PropTypes, and the description is pulled from JSDoc comments on the PropTypes. It's pretty slick.