I'm using Storybook's Storyshots with Vue and loving it, but now I've created some custom directives that alter the DOM on $nextTick
, I'd like to be able to wait and take the storyshots after $nextTick
so the DOM is represented properly.
Can anyone help explain how I might achieve this?
My setup is:
initStoryshots({
configPath: 'src/_storybook',
suite: 'web-apps',
test: multiSnapshotWithOptions(),
});
Thanks!
For doing that you'll need to configure Jest to make async tests mounting yourself the stories. It sound's harder that it is actually. This is my configuration on storybook.spec.js