Skip to content

Commit

Permalink
Issue #3476889 - Fixed useEffect only running on load due to blank de…
Browse files Browse the repository at this point in the history
…ps. (#1309)

Co-authored-by: 
Alex Skrypnyk (AlexSkrypnyk)
Joshua Fernandes <83997348+joshua-salsadigital@users.noreply.github.com>
  • Loading branch information
alan-cole authored Oct 7, 2024
1 parent 132e319 commit 202a155
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion web/themes/contrib/civictheme/.storybook/preview.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import { decoratorDocs } from '../components/00-base/storybook/storybook.docs.ut

// Call attaching of behaviours.
addDecorator((storyFn) => {
useEffect(() => Drupal.attachBehaviors(), []);
useEffect(() => Drupal.attachBehaviors());
return storyFn();
});

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import { decoratorDocs } from '../components_combined/00-base/storybook/storyboo

// Call attaching of behaviours.
addDecorator((storyFn) => {
useEffect(() => Drupal.attachBehaviors(), []);
useEffect(() => Drupal.attachBehaviors());
return storyFn();
});

Expand Down

0 comments on commit 202a155

Please sign in to comment.