Skip to content

Commit

Permalink
Set error level for Storybook as well
Browse files Browse the repository at this point in the history
+ fix EuiProvider demo not working since the organization changes - ID follows title
  • Loading branch information
cee-chen committed Mar 27, 2024
1 parent 2ce8f81 commit 476eda6
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion .storybook/preview.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,12 @@ import { writingModeStyles } from './writing_mode.styles';
// once all EUI components are converted to Emotion
import '../dist/eui_theme_light.css';

/**
* Ensure that any provider errors throw & warn us early
*/
import { setEuiDevProviderWarning } from '../src/services';
setEuiDevProviderWarning('error');

/**
* Prop controls
*/
Expand All @@ -51,7 +57,7 @@ const preview: Preview = {
(Story, context) => (
<EuiProvider
colorMode={context.globals.colorMode}
{...(context.componentId === 'euiprovider' && context.args)}
{...(context.componentId === 'theming-euiprovider' && context.args)}
>
<div
css={[
Expand Down

0 comments on commit 476eda6

Please sign in to comment.