From edc9ce12a1288cbdc23f962316aef106c1efa8b8 Mon Sep 17 00:00:00 2001 From: Mads Thines Date: Mon, 18 Jul 2022 13:50:10 +0200 Subject: [PATCH] fix(storybook): adjusted `STORYBOOK_` (#11171) Corrected the `STORYBOOK_` RegExp to match documentation https://storybook.js.org/docs/react/configure/environment-variable --- packages/react/plugins/storybook/index.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/react/plugins/storybook/index.ts b/packages/react/plugins/storybook/index.ts index ca8b2c40f77bd..562896ac65a61 100644 --- a/packages/react/plugins/storybook/index.ts +++ b/packages/react/plugins/storybook/index.ts @@ -18,7 +18,7 @@ function getClientEnvironment(mode) { // Grab NODE_ENV and NX_* and STORYBOOK_* environment variables and prepare them to be // injected into the application via DefinePlugin in webpack configuration. const NX_PREFIX = /^NX_/i; - const STORYBOOK_PREFIX = /^STORYBOOK__/i; + const STORYBOOK_PREFIX = /^STORYBOOK_/i; const raw = Object.keys(process.env) .filter((key) => NX_PREFIX.test(key) || STORYBOOK_PREFIX.test(key))