Skip to content

Commit

Permalink
Merge pull request #5340 from storybooks/add-STORY_UNCHANGED
Browse files Browse the repository at this point in the history
ADD a STORY_UNCHANGED event
  • Loading branch information
ndelangen authored Jan 23, 2019
2 parents 4508aa4 + 3f3f0af commit 1b5b407
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions lib/core-events/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ enum events {
APPLY_SHORTCUT = 'applyShortcut',
STORY_ADDED = 'storyAdded',
STORY_CHANGED = 'storyChanged',
STORY_UNCHANGED = 'storyUnchanged',
FORCE_RE_RENDER = 'forceReRender',
REGISTER_SUBSCRIPTION = 'registerSubscription',
STORY_INIT = 'storyInit',
Expand Down
1 change: 1 addition & 0 deletions lib/core/src/client/preview/start.js
Original file line number Diff line number Diff line change
Expand Up @@ -123,6 +123,7 @@ export default function start(render, { decorateStory } = {}) {
kind === previousKind &&
previousStory === name
) {
addons.getChannel().emit(Events.STORY_UNCHANGED, id);
return;
}

Expand Down

0 comments on commit 1b5b407

Please sign in to comment.