Cleaning up deps and comments

This commit is contained in:
Alexandre BODIN 2017-06-14 23:23:16 +02:00
parent 514f4b775c
commit 5a6472d751
2 changed files with 11 additions and 3 deletions

View File

@ -21,8 +21,16 @@
"dependencies": {
"@storybook/addons": "^3.1.2",
"babel-runtime": "^6.23.0",
"prop-types": "^15.5.10",
"react": "^15.5.4",
"util-deprecate": "^1.0.2"
},
"devDependencies": {
"prop-types": "^15.5.10",
"react": "^15.5.4"
},
"peerDependencies": {
"react": "*"
},
"optionalDependencies": {
"@types/react": "^15.0.24"
}
}

View File

@ -4,9 +4,9 @@ import { WithNotes as ReactWithNotes } from './react';
export const withNotes = ({ notes }) => {
const channel = addons.getChannel();
// send the notes to the channel.
return getStory => () => {
// send the notes to the channel before the story is rendered
channel.emit('storybook/notes/add_notes', notes);
return getStory();
};