@storybook/react-webpack5 7.0.0-rc.0 → 7.0.0-rc.10

Sign up to get free protection for your applications and to get access to all the features.
Files changed (2) hide show
  1. package/dist/preset.d.ts +12 -1
  2. package/package.json +5 -5
package/dist/preset.d.ts CHANGED
@@ -887,7 +887,6 @@ interface BuilderOptions {
887
887
  cache?: FileSystemCache;
888
888
  configDir: string;
889
889
  docsMode?: boolean;
890
- env?: (envs: Record<string, string>) => Record<string, string>;
891
890
  features?: StorybookConfig['features'];
892
891
  versionCheck?: VersionCheck;
893
892
  releaseNotesData?: ReleaseNotesData;
@@ -1029,6 +1028,10 @@ interface StorybookConfig {
1029
1028
  * Modify or return babel config.
1030
1029
  */
1031
1030
  babel?: (config: TransformOptions, options: Options) => TransformOptions | Promise<TransformOptions>;
1031
+ /**
1032
+ * Modify or return env config.
1033
+ */
1034
+ env?: PresetValue<Record<string, string>>;
1032
1035
  /**
1033
1036
  * Modify or return babel config.
1034
1037
  */
@@ -1058,6 +1061,14 @@ interface StorybookConfig {
1058
1061
  */
1059
1062
  previewHead?: PresetValue<string>;
1060
1063
  previewBody?: PresetValue<string>;
1064
+ /**
1065
+ * Programatically override the preview's main page template.
1066
+ * This should return a reference to a file containing an `.ejs` template
1067
+ * that will be interpolated with environment variables.
1068
+ *
1069
+ * @example '.storybook/index.ejs'
1070
+ */
1071
+ previewMainTemplate?: string;
1061
1072
  }
1062
1073
  type PresetValue<T> = T | ((config: T, options: Options) => T | Promise<T>);
1063
1074
  type PresetProperty<K, TStorybookConfig = StorybookConfig> = TStorybookConfig[K extends keyof TStorybookConfig ? K : never] | PresetPropertyFn<K, TStorybookConfig>;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@storybook/react-webpack5",
3
- "version": "7.0.0-rc.0",
3
+ "version": "7.0.0-rc.10",
4
4
  "description": "Storybook for React: Develop React Component in isolation with Hot Reloading.",
5
5
  "keywords": [
6
6
  "storybook"
@@ -48,9 +48,9 @@
48
48
  "prep": "../../../scripts/prepare/bundle.ts"
49
49
  },
50
50
  "dependencies": {
51
- "@storybook/builder-webpack5": "7.0.0-rc.0",
52
- "@storybook/preset-react-webpack": "7.0.0-rc.0",
53
- "@storybook/react": "7.0.0-rc.0",
51
+ "@storybook/builder-webpack5": "7.0.0-rc.10",
52
+ "@storybook/preset-react-webpack": "7.0.0-rc.10",
53
+ "@storybook/react": "7.0.0-rc.10",
54
54
  "@types/node": "^16.0.0"
55
55
  },
56
56
  "devDependencies": {
@@ -83,5 +83,5 @@
83
83
  ],
84
84
  "platform": "node"
85
85
  },
86
- "gitHead": "6d1bcb2579203a3075467a2ba83738d854545053"
86
+ "gitHead": "dd10adf7821c47f0d3a2e6a45d80eea2b906c3a2"
87
87
  }