mirror of
https://github.com/storybookjs/storybook.git
synced 2025-04-09 00:19:13 +08:00
21 lines
423 B
JavaScript
21 lines
423 B
JavaScript
import { View } from 'backbone.marionette';
|
|
|
|
import { storiesOf } from '@storybook/marionette';
|
|
|
|
storiesOf('Demo', module).add(
|
|
'button',
|
|
() =>
|
|
new View({
|
|
template: () => '<button id="my_button">some button</button>',
|
|
ui: {
|
|
button: '#my_button',
|
|
},
|
|
triggers: {
|
|
'click @ui.button': 'click',
|
|
},
|
|
onClick() {
|
|
console.log('button clicked');
|
|
},
|
|
})
|
|
);
|