Changelog
v2.1.0 (2016/11/13)
// before 2.1.0 we can do
play('this is my component', module)
.add('with text', h => h(MyCompoent))
// now we can also
play(MyComponent, module)
.displayName('this is my component')
.add('with text', h => h(MyCompoent))
Changelog
v2.0.0 (2016/11/03)
play entry
syntax to be more similar to react-storybookvue-play-cli
to support new core changesChangelog
v2.0.0-beta.1 (2016/10/30)
play.describe
method for adding playspotplay.describe('Button', add => {
add('with text', '<button>text</button>')
})
// if no callback function, it returns the `add` function
const addButton = play.describe('Button')
addButton('with text', '<button>text</button>')
play.start
now only needs the selector
argument, and it defaults to #app
// mount the app to #root element
play.start('#root')
action
to replace this.$log
and this.$clear
playspot
is for the thing you play.describe
scenario
is a scenario for demonstrating your playspotplay app
is the whole app// describe a playspot
play.describe('button', add => {
// add a scenario called 'with text'
add('with text', '<button>text</button>')
})