@storybook/server 6.4.0-beta.6 → 6.4.0-rc.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -130,7 +130,7 @@ Static parameters can be defined using the `params` story parameter. For example
130
130
  }
131
131
  ```
132
132
 
133
- The Red and Green story HTML will be fetched from the urls `server.url/controls/button?color=red&label=Stopr` and `server.url/controls/button?color=green&label=OK`
133
+ The Red and Green story HTML will be fetched from the urls `server.url/controls/button?color=red&label=Stop` and `server.url/controls/button?color=green&label=OK`
134
134
 
135
135
  Like all story parameters server params can be defined in the default export and overridden in stories.
136
136
 
@@ -4,9 +4,12 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.webpack = webpack;
7
+ exports.config = void 0;
7
8
 
8
9
  var _path = _interopRequireDefault(require("path"));
9
10
 
11
+ var _coreCommon = require("@storybook/core-common");
12
+
10
13
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
11
14
 
12
15
  // eslint-disable-next-line import/no-extraneous-dependencies
@@ -22,4 +25,10 @@ function webpack(config) {
22
25
  use: [_path.default.resolve(__dirname, './loader.js'), 'yaml-loader']
23
26
  });
24
27
  return config;
25
- }
28
+ }
29
+
30
+ var config = function (entry = []) {
31
+ return [...entry, (0, _coreCommon.findDistEsm)(__dirname, 'client/preview/config')];
32
+ };
33
+
34
+ exports.config = config;
@@ -1,5 +1,6 @@
1
1
  // eslint-disable-next-line import/no-extraneous-dependencies
2
2
  import path from 'path';
3
+ import { findDistEsm } from '@storybook/core-common';
3
4
  export function webpack(config) {
4
5
  config.module.rules.push({
5
6
  type: 'javascript/auto',
@@ -12,4 +13,7 @@ export function webpack(config) {
12
13
  use: [path.resolve(__dirname, './loader.js'), 'yaml-loader']
13
14
  });
14
15
  return config;
15
- }
16
+ }
17
+ export var config = function (entry = []) {
18
+ return [...entry, findDistEsm(__dirname, 'client/preview/config')];
19
+ };
@@ -1,5 +1,6 @@
1
1
  // eslint-disable-next-line import/no-extraneous-dependencies
2
2
  import path from 'path';
3
+ import { findDistEsm } from '@storybook/core-common';
3
4
  export function webpack(config) {
4
5
  config.module.rules.push({
5
6
  type: 'javascript/auto',
@@ -12,4 +13,7 @@ export function webpack(config) {
12
13
  use: [path.resolve(__dirname, './loader.js'), 'yaml-loader']
13
14
  });
14
15
  return config;
15
- }
16
+ }
17
+ export var config = function (entry = []) {
18
+ return [...entry, findDistEsm(__dirname, 'client/preview/config')];
19
+ };
@@ -13,9 +13,9 @@ interface ClientApi extends ClientStoryApi<ServerFramework['storyResult']> {
13
13
  }
14
14
  export declare const storiesOf: ClientApi['storiesOf'];
15
15
  export declare const configure: ClientApi['configure'];
16
- export declare const addDecorator: (decorator: import("@storybook/csf").DecoratorFunction<ServerFramework, import("@storybook/addons").Args>) => void, addParameters: ({ globals, globalTypes, ...parameters }: import("@storybook/csf").Parameters & {
16
+ export declare const addDecorator: (() => never) | ((decorator: import("@storybook/csf").DecoratorFunction<ServerFramework, import("@storybook/addons").Args>) => void), addParameters: (() => never) | (({ globals, globalTypes, ...parameters }: import("@storybook/csf").Parameters & {
17
17
  globals?: import("@storybook/csf").Globals;
18
18
  globalTypes?: import("@storybook/csf").GlobalTypes;
19
- }) => void, clearDecorators: () => void, setAddon: (addon: any) => void, getStorybook: () => import("@storybook/client-api/dist/ts3.9/ClientApi").GetStorybookKind<ServerFramework>[], raw: () => import("@storybook/store").BoundStory<ServerFramework>[];
20
- export declare const forceReRender: () => void;
19
+ }) => void), clearDecorators: (() => never) | (() => void), setAddon: (() => never) | ((addon: any) => void), getStorybook: (() => never) | (() => import("@storybook/client-api/dist/ts3.9/ClientApi").GetStorybookKind<ServerFramework>[]), raw: (() => never) | (() => import("@storybook/store").BoundStory<ServerFramework>[]);
20
+ export declare const forceReRender: (() => never) | (() => void);
21
21
  export {};
@@ -1,2 +1,4 @@
1
1
  import { Configuration } from 'webpack';
2
+ import { StorybookConfig } from '@storybook/core-common';
2
3
  export declare function webpack(config: Configuration): Configuration;
4
+ export declare const config: StorybookConfig['config'];
@@ -13,9 +13,9 @@ interface ClientApi extends ClientStoryApi<ServerFramework['storyResult']> {
13
13
  }
14
14
  export declare const storiesOf: ClientApi['storiesOf'];
15
15
  export declare const configure: ClientApi['configure'];
16
- export declare const addDecorator: (decorator: import("@storybook/csf").DecoratorFunction<ServerFramework, import("@storybook/addons").Args>) => void, addParameters: ({ globals, globalTypes, ...parameters }: import("@storybook/csf").Parameters & {
16
+ export declare const addDecorator: (() => never) | ((decorator: import("@storybook/csf").DecoratorFunction<ServerFramework, import("@storybook/addons").Args>) => void), addParameters: (() => never) | (({ globals, globalTypes, ...parameters }: import("@storybook/csf").Parameters & {
17
17
  globals?: import("@storybook/csf").Globals;
18
18
  globalTypes?: import("@storybook/csf").GlobalTypes;
19
- }) => void, clearDecorators: () => void, setAddon: (addon: any) => void, getStorybook: () => import("@storybook/client-api/dist/ts3.9/ClientApi").GetStorybookKind<ServerFramework>[], raw: () => import("@storybook/store").BoundStory<ServerFramework>[];
20
- export declare const forceReRender: () => void;
19
+ }) => void), clearDecorators: (() => never) | (() => void), setAddon: (() => never) | ((addon: any) => void), getStorybook: (() => never) | (() => import("@storybook/client-api/dist/ts3.9/ClientApi").GetStorybookKind<ServerFramework>[]), raw: (() => never) | (() => import("@storybook/store").BoundStory<ServerFramework>[]);
20
+ export declare const forceReRender: (() => never) | (() => void);
21
21
  export {};
@@ -1,2 +1,4 @@
1
1
  import { Configuration } from 'webpack';
2
+ import { StorybookConfig } from '@storybook/core-common';
2
3
  export declare function webpack(config: Configuration): Configuration;
4
+ export declare const config: StorybookConfig['config'];
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@storybook/server",
3
- "version": "6.4.0-beta.6",
3
+ "version": "6.4.0-rc.0",
4
4
  "description": "Storybook for Server: View HTML snippets from a server in isolation with Hot Reloading.",
5
5
  "keywords": [
6
6
  "storybook"
@@ -45,15 +45,15 @@
45
45
  "prepare": "node ../../scripts/prepare.js"
46
46
  },
47
47
  "dependencies": {
48
- "@storybook/addons": "6.4.0-beta.6",
49
- "@storybook/api": "6.4.0-beta.6",
50
- "@storybook/client-api": "6.4.0-beta.6",
51
- "@storybook/core": "6.4.0-beta.6",
52
- "@storybook/core-common": "6.4.0-beta.6",
53
- "@storybook/csf": "0.0.2--canary.6aca495.0",
54
- "@storybook/node-logger": "6.4.0-beta.6",
55
- "@storybook/preview-web": "6.4.0-beta.6",
56
- "@storybook/store": "6.4.0-beta.6",
48
+ "@storybook/addons": "6.4.0-rc.0",
49
+ "@storybook/api": "6.4.0-rc.0",
50
+ "@storybook/client-api": "6.4.0-rc.0",
51
+ "@storybook/core": "6.4.0-rc.0",
52
+ "@storybook/core-common": "6.4.0-rc.0",
53
+ "@storybook/csf": "0.0.2--canary.87bc651.0",
54
+ "@storybook/node-logger": "6.4.0-rc.0",
55
+ "@storybook/preview-web": "6.4.0-rc.0",
56
+ "@storybook/store": "6.4.0-rc.0",
57
57
  "@types/webpack-env": "^1.16.0",
58
58
  "core-js": "^3.8.2",
59
59
  "global": "^4.4.0",
@@ -75,6 +75,6 @@
75
75
  "publishConfig": {
76
76
  "access": "public"
77
77
  },
78
- "gitHead": "6e415afb51d87edbdf8598cb3260be1023426db6",
78
+ "gitHead": "812e75b32c7fe222b872961a83c05cc8ece36a36",
79
79
  "sbmodern": "dist/modern/client/index.js"
80
80
  }
package/preset.js CHANGED
@@ -1,7 +1 @@
1
- function config(entry = []) {
2
- return [...entry, require.resolve('./dist/esm/client/preview/config')];
3
- }
4
-
5
- module.exports = {
6
- config,
7
- };
1
+ module.exports = require('./dist/cjs/server/framework-preset-server');