From 4753e202d3eb1f9449c4d9a74304a07eb0b2d314 Mon Sep 17 00:00:00 2001 From: Tom Coleman Date: Sun, 3 Mar 2019 11:04:35 +1100 Subject: [PATCH] ADD new story-level decorators to angular di stories --- .../component-with-di/di.component.stories.ts | 19 ++++++++++++------- 1 file changed, 12 insertions(+), 7 deletions(-) diff --git a/examples/angular-cli/src/stories/component-with-di/di.component.stories.ts b/examples/angular-cli/src/stories/component-with-di/di.component.stories.ts index 6059f9ecc77..a553eb7ac00 100644 --- a/examples/angular-cli/src/stories/component-with-di/di.component.stories.ts +++ b/examples/angular-cli/src/stories/component-with-di/di.component.stories.ts @@ -9,10 +9,15 @@ storiesOf('Custom|Dependencies', module) title: 'Component dependencies', }, })) - .addDecorator(withKnobs) - .add('inputs and inject dependencies with knobs', () => ({ - component: DiComponent, - props: { - title: text('title', 'Component dependencies'), - }, - })); + .add( + 'inputs and inject dependencies with knobs', + () => ({ + component: DiComponent, + props: { + title: text('title', 'Component dependencies'), + }, + }), + { + decorators: [withKnobs], + } + );