{"action":"created","issue":{"url":"https://api.github.com/repos/storybooks/storybook/issues/993","repository_url":"https://api.github.com/repos/storybooks/storybook","labels_url":"https://api.github.com/repos/storybooks/storybook/issues/993/labels{/name}","comments_url":"https://api.github.com/repos/storybooks/storybook/issues/993/comments","events_url":"https://api.github.com/repos/storybooks/storybook/issues/993/events","html_url":"https://github.com/storybooks/storybook/issues/993","id":226362435,"number":993,"title":"Allow passing options to `storiesOf().add()` as hook to customizing story behaviour in plugins","user":{"login":"theinterned","id":2694,"avatar_url":"https://avatars2.githubusercontent.com/u/2694?v=4","gravatar_id":"","url":"https://api.github.com/users/theinterned","html_url":"https://github.com/theinterned","followers_url":"https://api.github.com/users/theinterned/followers","following_url":"https://api.github.com/users/theinterned/following{/other_user}","gists_url":"https://api.github.com/users/theinterned/gists{/gist_id}","starred_url":"https://api.github.com/users/theinterned/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/theinterned/subscriptions","organizations_url":"https://api.github.com/users/theinterned/orgs","repos_url":"https://api.github.com/users/theinterned/repos","events_url":"https://api.github.com/users/theinterned/events{/privacy}","received_events_url":"https://api.github.com/users/theinterned/received_events","type":"User","site_admin":false},"labels":[{"id":589391175,"url":"https://api.github.com/repos/storybooks/storybook/labels/api:%20addons","name":"api: addons","color":"0052cc","default":false},{"id":589393454,"url":"https://api.github.com/repos/storybooks/storybook/labels/api:%20stories","name":"api: stories","color":"0052cc","default":false},{"id":343576456,"url":"https://api.github.com/repos/storybooks/storybook/labels/feature%20request","name":"feature request","color":"9B58D8","default":false},{"id":622392928,"url":"https://api.github.com/repos/storybooks/storybook/labels/merged","name":"merged","color":"0e8a16","default":false}],"state":"open","locked":false,"assignee":{"login":"theinterned","id":2694,"avatar_url":"https://avatars2.githubusercontent.com/u/2694?v=4","gravatar_id":"","url":"https://api.github.com/users/theinterned","html_url":"https://github.com/theinterned","followers_url":"https://api.github.com/users/theinterned/followers","following_url":"https://api.github.com/users/theinterned/following{/other_user}","gists_url":"https://api.github.com/users/theinterned/gists{/gist_id}","starred_url":"https://api.github.com/users/theinterned/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/theinterned/subscriptions","organizations_url":"https://api.github.com/users/theinterned/orgs","repos_url":"https://api.github.com/users/theinterned/repos","events_url":"https://api.github.com/users/theinterned/events{/privacy}","received_events_url":"https://api.github.com/users/theinterned/received_events","type":"User","site_admin":false},"assignees":[{"login":"theinterned","id":2694,"avatar_url":"https://avatars2.githubusercontent.com/u/2694?v=4","gravatar_id":"","url":"https://api.github.com/users/theinterned","html_url":"https://github.com/theinterned","followers_url":"https://api.github.com/users/theinterned/followers","following_url":"https://api.github.com/users/theinterned/following{/other_user}","gists_url":"https://api.github.com/users/theinterned/gists{/gist_id}","starred_url":"https://api.github.com/users/theinterned/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/theinterned/subscriptions","organizations_url":"https://api.github.com/users/theinterned/orgs","repos_url":"https://api.github.com/users/theinterned/repos","events_url":"https://api.github.com/users/theinterned/events{/privacy}","received_events_url":"https://api.github.com/users/theinterned/received_events","type":"User","site_admin":false},{"login":"tmeasday","id":132554,"avatar_url":"https://avatars1.githubusercontent.com/u/132554?v=4","gravatar_id":"","url":"https://api.github.com/users/tmeasday","html_url":"https://github.com/tmeasday","followers_url":"https://api.github.com/users/tmeasday/followers","following_url":"https://api.github.com/users/tmeasday/following{/other_user}","gists_url":"https://api.github.com/users/tmeasday/gists{/gist_id}","starred_url":"https://api.github.com/users/tmeasday/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tmeasday/subscriptions","organizations_url":"https://api.github.com/users/tmeasday/orgs","repos_url":"https://api.github.com/users/tmeasday/repos","events_url":"https://api.github.com/users/tmeasday/events{/privacy}","received_events_url":"https://api.github.com/users/tmeasday/received_events","type":"User","site_admin":false},{"login":"ndelangen","id":3070389,"avatar_url":"https://avatars2.githubusercontent.com/u/3070389?v=4","gravatar_id":"","url":"https://api.github.com/users/ndelangen","html_url":"https://github.com/ndelangen","followers_url":"https://api.github.com/users/ndelangen/followers","following_url":"https://api.github.com/users/ndelangen/following{/other_user}","gists_url":"https://api.github.com/users/ndelangen/gists{/gist_id}","starred_url":"https://api.github.com/users/ndelangen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ndelangen/subscriptions","organizations_url":"https://api.github.com/users/ndelangen/orgs","repos_url":"https://api.github.com/users/ndelangen/repos","events_url":"https://api.github.com/users/ndelangen/events{/privacy}","received_events_url":"https://api.github.com/users/ndelangen/received_events","type":"User","site_admin":false}],"milestone":null,"comments":17,"created_at":"2017-05-04T18:03:05Z","updated_at":"2018-03-29T09:30:11Z","closed_at":null,"author_association":"CONTRIBUTOR","body":"Having the generic ability to pass options alongside each story to the `storiesOf` and `add` method would open the door to some easier per-story customization in decorators or other add-ons.\r\n\r\nI see few possible solutions: \r\n\r\n# Option 1: add an `options` argument\r\nMake `options` an argument to `storiesOf` and `add`. This would look like this:\r\n\r\n```js\r\nstoriesOf('kind', kindOptions)\r\n  .add('title', render, storyOptions);\r\n```\r\n\r\n# Option 2: Make `storiesOf` and `add` accept a single options hash arg\r\nChange the api for `storiesOf` and `add` so that they accept a single options arg. Something along the lines of:\r\n\r\n```js\r\nstoriesOf({title: 'kind title'})\r\n  .add({\r\n    title: 'story title', \r\n    render, \r\n    myOtherOption\r\n  });\r\n```\r\n\r\n_**Note:** Moved the JSX syntax proposal to #1006_"},"comment":{"url":"https://api.github.com/repos/storybooks/storybook/issues/comments/377178657","html_url":"https://github.com/storybooks/storybook/issues/993#issuecomment-377178657","issue_url":"https://api.github.com/repos/storybooks/storybook/issues/993","id":377178657,"user":{"login":"Hypnosphi","id":6651625,"avatar_url":"https://avatars3.githubusercontent.com/u/6651625?v=4","gravatar_id":"","url":"https://api.github.com/users/Hypnosphi","html_url":"https://github.com/Hypnosphi","followers_url":"https://api.github.com/users/Hypnosphi/followers","following_url":"https://api.github.com/users/Hypnosphi/following{/other_user}","gists_url":"https://api.github.com/users/Hypnosphi/gists{/gist_id}","starred_url":"https://api.github.com/users/Hypnosphi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Hypnosphi/subscriptions","organizations_url":"https://api.github.com/users/Hypnosphi/orgs","repos_url":"https://api.github.com/users/Hypnosphi/repos","events_url":"https://api.github.com/users/Hypnosphi/events{/privacy}","received_events_url":"https://api.github.com/users/Hypnosphi/received_events","type":"User","site_admin":false},"created_at":"2018-03-29T09:30:11Z","updated_at":"2018-03-29T09:30:11Z","author_association":"OWNER","body":"Released as [`4.0.0-alpha.0`](https://github.com/storybooks/storybook/releases/tag/v4.0.0-alpha.0)"}}
{"actor":{"display_login":"Hypnosphi"}}