view Vue component with mock data
Description
- Working on MR Widget a lot of the time you want to see it render some particular state.
- We have mock data for most states in
spec
directory - hardcoding component code with mock data is hacky
- Mocking network requests in Chrome is tedious
Proposal
Add one of:
- storybook
- vue-play
- our own thing
- some kind of devtool that lets you change component state easily
Links / references
Working Vue example with storybook - https://github.com/storybooks/storybook/tree/add-app-vue/examples/vue-kitchen-sink
Documentation blurb
- Storybook loads styles served from GDK, so GDK needs to be running on port 3000. For other ports, configure in
.storybook/preview-head.html
- run
yarn storybook
to start storybook dev server - visit localhost:6006 to see components rendered in isolation
Edited by Simon Knox