Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Release: Prerelease 8.2.0-alpha.1 #27128

Merged
merged 60 commits into from
May 15, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
60 commits
Select commit Hold shift + click to select a range
0c5946f
chore: bump `markdown-to-jsx` to v7.4.5
xyy94813 Mar 30, 2024
942579a
docs: update outdated guide to make code open by default
abiriadev Apr 18, 2024
c3e3ab9
feat: #25510 add optional --no-dev option to storybook init CLI
Apr 22, 2024
b300ae3
chore: clean up the usage of doInitiate in sandbox task
Apr 23, 2024
cf562cc
Only add react-docgen info in the file a component is defined
glenjamin Apr 28, 2024
b9e316d
Merge branch 'next' into feature/bump-mdx-js
xyy94813 May 2, 2024
ed5eb98
Fix typo in test-runner-image-snapshot-testing.js.mdx
hakshu25 May 7, 2024
88f8c17
Fix missing require waitForPageReady in test-runner-image-snapshot-te…
hakshu25 May 7, 2024
3312cd6
[ImgBot] Optimize images
ImgBotApp May 7, 2024
e0acab3
CLI: init Svelte projects with @storybook/addon-svelte-csf
benmccann May 8, 2024
cc3ffe7
Revert "Fix missing require waitForPageReady in test-runner-image-sna…
hakshu25 May 8, 2024
becd314
Merge branch 'next' into patch-1
hakshu25 May 8, 2024
0f4d2c3
Fix typing for main.framework/builder fields
valentinpalkovic May 10, 2024
3b65061
Next.js: avoid conflicts with the raw loader
seanparmelee May 10, 2024
6d7ae05
feat: upgrade webpack-virtual-modules to 0.6.0
fyodorovandrei May 12, 2024
56b4a91
feat: remove @types/webpack-virtual-modules since the package bundles…
fyodorovandrei May 12, 2024
180465b
Add typing for NextImage to main framework options type
valentinpalkovic May 13, 2024
e21f7d4
Update NextImage type in framework options to make all keys partial
valentinpalkovic May 13, 2024
5fe26a9
Merge branch 'next' into csf-init
JReinhold May 13, 2024
a36c95a
address TS errors
seanparmelee May 13, 2024
4993b00
Merge branch 'next' into raw-conflicts
seanparmelee May 13, 2024
8f475a0
Merge branch 'next' into upgrade-webpack-virtual-modules
valentinpalkovic May 14, 2024
0a9912b
Fix lints
JReinhold May 14, 2024
033cb40
Merge branch 'next' into csf-init
JReinhold May 14, 2024
8983941
Vite: Only add react-docgen info in the file a component is defined
valentinpalkovic May 14, 2024
d80070b
Merge branch 'next' into docgen-re-export
valentinpalkovic May 14, 2024
405b1f5
Update lock file
valentinpalkovic May 14, 2024
c0ca9ed
Small refactor
valentinpalkovic May 14, 2024
d1a3474
Merge branch 'next' into fastfrwrd/25510-no-dev-for-init
valentinpalkovic May 14, 2024
4b3bb37
Merge branch 'next' into csf-init
benmccann May 14, 2024
9fa6650
Chore: Fix formatting
valentinpalkovic May 14, 2024
b6c8e1a
remove the ensure-next-ahead script completely
JReinhold May 14, 2024
87a5883
Merge branch 'next' into patch-1
jonniebigodes May 14, 2024
56b17c6
Merge pull request #27051 from hakshu25/patch-1
jonniebigodes May 14, 2024
73823d0
Merge branch 'next' into jeppe/remove-ensure-next
JReinhold May 14, 2024
6483a4f
Merge branch 'next' into csf-init
JReinhold May 14, 2024
53f2e3b
Merge branch 'next-release' into next
storybook-bot May 14, 2024
f4d3e75
Merge pull request #27119 from storybookjs/valentin/fix-formatting
valentinpalkovic May 14, 2024
46646d2
Merge pull request #27105 from storybookjs/valentin/nextjs-add-image-…
valentinpalkovic May 14, 2024
7b503b3
Merge remote-tracking branch 'origin/next' into valentin/provide-rela…
valentinpalkovic May 14, 2024
fdd0256
Merge remote-tracking branch 'origin/next' into valentin/provide-rela…
valentinpalkovic May 14, 2024
0fe6c75
Merge pull request #27102 from fyodorovandrei/upgrade-webpack-virtual…
valentinpalkovic May 14, 2024
f5fc402
Merge pull request #27093 from seanparmelee/raw-conflicts
valentinpalkovic May 14, 2024
3a1facb
Merge pull request #27121 from storybookjs/jeppe/remove-ensure-next
ndelangen May 14, 2024
691069c
Merge pull request #26967 from glenjamin/docgen-re-export
valentinpalkovic May 14, 2024
1e4aadc
Merge pull request #26694 from xyy94813/feature/bump-mdx-js
valentinpalkovic May 14, 2024
4b21a08
Merge pull request #27070 from benmccann/csf-init
JReinhold May 14, 2024
e540371
Merge branch 'next' into patch-1
jonniebigodes May 14, 2024
e60fc12
Merge pull request #26918 from fastfrwrd/fastfrwrd/25510-no-dev-for-init
valentinpalkovic May 14, 2024
a71ed44
Merge branch 'next' into patch-1
jonniebigodes May 14, 2024
991c9e2
Merge branch 'next' into imgbot
jonniebigodes May 14, 2024
1ae28db
Merge pull request #27088 from storybookjs/valentin/provide-relaxed-t…
valentinpalkovic May 14, 2024
56d58c3
Merge pull request #27062 from storybookjs/imgbot
jonniebigodes May 14, 2024
eafbe7e
Merge branch 'next' into patch-1
jonniebigodes May 14, 2024
78bbb6c
Merge pull request #26872 from abiriadev/patch-1
jonniebigodes May 14, 2024
babad72
Docs: Fix Stories block tag-filtering behavior in MDX
shilman May 15, 2024
ccb9b5a
Don't require of prop in Subtitle doc block
JReinhold May 15, 2024
ce3d0d5
Merge pull request #27144 from storybookjs/shilman/27143-fix-stories-…
shilman May 15, 2024
1ba1a7e
Merge pull request #27147 from storybookjs/jeppe/27139-bug-unable-to-…
shilman May 15, 2024
1b863a5
Write changelog for 8.2.0-alpha.1 [skip ci]
storybook-bot May 15, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 0 additions & 12 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -154,18 +154,6 @@ jobs:
git merge ${{ github.ref_name }}
git push origin ${{ steps.target.outputs.target }}

- name: Ensure `next` is a minor version ahead of `main`
if: steps.target.outputs.target == 'main'
run: |
git checkout next
git pull

yarn release:ensure-next-ahead --main-version "${{ steps.version.outputs.current-version }}"

git add ..
git diff --staged --quiet || git commit -m "Bump next to be one minor ahead of main [skip ci]"
git push origin next

- name: Sync CHANGELOG.md from `main` to `next`
if: steps.target.outputs.target == 'main'
working-directory: .
Expand Down
13 changes: 13 additions & 0 deletions CHANGELOG.prerelease.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,16 @@
## 8.2.0-alpha.1

- CLI: Add optional `--dev` and `--no-dev` options to `storybook init` CLI - [#26918](https://github.com/storybookjs/storybook/pull/26918), thanks @fastfrwrd!
- CLI: Include `@storybook/addon-svelte-csf` when initializing new projects - [#27070](https://github.com/storybookjs/storybook/pull/27070), thanks @benmccann!
- Dependency: Upgrade `webpack-virtual-modules` to 0.6.0 - [#27102](https://github.com/storybookjs/storybook/pull/27102), thanks @fyodorovandrei!
- Dependency: bump `markdown-to-jsx` to v7.4.5 - [#26694](https://github.com/storybookjs/storybook/pull/26694), thanks @xyy94813!
- Docgen: Only add react-docgen info when a component is defined in the file - [#26967](https://github.com/storybookjs/storybook/pull/26967), thanks @glenjamin!
- Docs: Fix MDX Stories block tag-filtering behavior - [#27144](https://github.com/storybookjs/storybook/pull/27144), thanks @shilman!
- Docs: Fix Subtitle block when no `of` prop passed - [#27147](https://github.com/storybookjs/storybook/pull/27147), thanks @JReinhold!
- Next.js: Add typing for NextImage to main framework options type - [#27105](https://github.com/storybookjs/storybook/pull/27105), thanks @valentinpalkovic!
- Next.js: Avoid conflicts with the raw loader - [#27093](https://github.com/storybookjs/storybook/pull/27093), thanks @seanparmelee!
- Types: Fix typing for main.framework/builder fields - [#27088](https://github.com/storybookjs/storybook/pull/27088), thanks @valentinpalkovic!

## 8.2.0-alpha.0


Expand Down
Binary file modified CONTRIBUTING/prerelease-workflow-inputs.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
8 changes: 4 additions & 4 deletions code/addons/docs/docs/docspage.md
Original file line number Diff line number Diff line change
Expand Up @@ -165,10 +165,10 @@ You can override this default behavior in `.storybook/preview.js` (or in any of
```js
export const parameters = {
docs: {
source: {
state: 'open',
},
},
canvas: {
sourceState: 'shown'
}
}
};
```

Expand Down
4 changes: 1 addition & 3 deletions code/addons/docs/src/preview.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,7 @@ export const parameters: any = {
filter: (story: PreparedStory) => {
const tags = story.tags || [];
return (
tags.includes('autodocs') &&
tags.filter((tag) => excludeTags[tag]).length === 0 &&
!story.parameters.docs?.disable
tags.filter((tag) => excludeTags[tag]).length === 0 && !story.parameters.docs?.disable
);
},
},
Expand Down
3 changes: 1 addition & 2 deletions code/builders/builder-webpack5/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -96,13 +96,12 @@
"webpack": "5",
"webpack-dev-middleware": "^6.1.2",
"webpack-hot-middleware": "^2.25.1",
"webpack-virtual-modules": "^0.5.0"
"webpack-virtual-modules": "^0.6.0"
},
"devDependencies": {
"@types/pretty-hrtime": "^1.0.0",
"@types/terser-webpack-plugin": "^5.2.0",
"@types/webpack-hot-middleware": "^2.25.6",
"@types/webpack-virtual-modules": "^0.1.1",
"pretty-hrtime": "^1.0.3",
"slash": "^5.0.0",
"typescript": "^5.3.2"
Expand Down
5 changes: 3 additions & 2 deletions code/frameworks/angular/src/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,10 @@ import {
BuilderOptions,
TypescriptOptions as TypescriptOptionsBuilder,
} from '@storybook/builder-webpack5';
import { CompatibleString } from '@storybook/types';

type FrameworkName = '@storybook/angular';
type BuilderName = '@storybook/builder-webpack5';
type FrameworkName = CompatibleString<'@storybook/angular'>;
type BuilderName = CompatibleString<'@storybook/builder-webpack5'>;

export type FrameworkOptions = AngularOptions & {
builder?: BuilderOptions;
Expand Down
5 changes: 3 additions & 2 deletions code/frameworks/ember/src/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,10 @@ import type {
BuilderOptions,
TypescriptOptions as TypescriptOptionsBuilder,
} from '@storybook/builder-webpack5';
import type { CompatibleString } from '@storybook/types';

type FrameworkName = '@storybook/ember-webpack5';
type BuilderName = '@storybook/builder-webpack5';
type FrameworkName = CompatibleString<'@storybook/ember-webpack5'>;
type BuilderName = CompatibleString<'@storybook/builder-webpack5'>;

export type FrameworkOptions = {
builder?: BuilderOptions;
Expand Down
1 change: 1 addition & 0 deletions code/frameworks/html-vite/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@
"@storybook/core-server": "workspace:*",
"@storybook/html": "workspace:*",
"@storybook/node-logger": "workspace:*",
"@storybook/types": "workspace:*",
"magic-string": "^0.30.0"
},
"devDependencies": {
Expand Down
6 changes: 3 additions & 3 deletions code/frameworks/html-vite/src/types.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import type { StorybookConfig as StorybookConfigBase } from '@storybook/types';
import type { StorybookConfig as StorybookConfigBase, CompatibleString } from '@storybook/types';
import type { StorybookConfigVite, BuilderOptions } from '@storybook/builder-vite';

type FrameworkName = '@storybook/html-vite';
type BuilderName = '@storybook/builder-vite';
type FrameworkName = CompatibleString<'@storybook/html-vite'>;
type BuilderName = CompatibleString<'@storybook/builder-vite'>;

export type FrameworkOptions = {
builder?: BuilderOptions;
Expand Down
1 change: 1 addition & 0 deletions code/frameworks/html-webpack5/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@
"@storybook/global": "^5.0.0",
"@storybook/html": "workspace:*",
"@storybook/preset-html-webpack": "workspace:*",
"@storybook/types": "workspace:*",
"@types/node": "^18.0.0"
},
"devDependencies": {
Expand Down
5 changes: 3 additions & 2 deletions code/frameworks/html-webpack5/src/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,10 @@ import type {
BuilderOptions,
TypescriptOptions as TypescriptOptionsBuilder,
} from '@storybook/builder-webpack5';
import type { CompatibleString } from '@storybook/types';

type FrameworkName = '@storybook/html-webpack5';
type BuilderName = '@storybook/builder-webpack5';
type FrameworkName = CompatibleString<'@storybook/html-webpack5'>;
type BuilderName = CompatibleString<'@storybook/builder-webpack5'>;

export type FrameworkOptions = {
builder?: BuilderOptions;
Expand Down
62 changes: 34 additions & 28 deletions code/frameworks/nextjs/src/swc/loader.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,10 @@ import type { Options } from '@storybook/types';
import type { NextConfig } from 'next';
import path from 'path';
import loadJsConfig from 'next/dist/build/load-jsconfig';
import type { Configuration as WebpackConfig } from 'webpack';

export const configureSWCLoader = async (
baseConfig: any,
baseConfig: WebpackConfig,
options: Options,
nextConfig: NextConfig
) => {
Expand All @@ -18,33 +19,38 @@ export const configureSWCLoader = async (

const { jsConfig } = await loadJsConfig(dir, nextConfig as any);

baseConfig.module.rules = [
...baseConfig.module.rules,
{
test: /\.((c|m)?(j|t)sx?)$/,
include: [getProjectRoot()],
exclude: [/(node_modules)/, ...Object.keys(virtualModules)],
enforce: 'post',
use: {
// we use our own patch because we need to remove tracing from the original code
// which is not possible otherwise
loader: require.resolve('./swc/next-swc-loader-patch.js'),
options: {
isServer: false,
rootDir: dir,
pagesDir: `${dir}/pages`,
appDir: `${dir}/apps`,
hasReactRefresh: isDevelopment,
jsConfig,
nextConfig,
supportedBrowsers: require('next/dist/build/utils').getSupportedBrowsers(
dir,
isDevelopment
),
swcCacheDir: path.join(dir, nextConfig?.distDir ?? '.next', 'cache', 'swc'),
bundleTarget: 'default',
},
const rawRule = baseConfig.module?.rules?.find(
(rule) => typeof rule === 'object' && rule?.resourceQuery?.toString() === '/raw/'
);

if (rawRule && typeof rawRule === 'object') {
rawRule.test = /^(?!__barrel_optimize__)/;
}

baseConfig.module?.rules?.push({
test: /\.((c|m)?(j|t)sx?)$/,
include: [getProjectRoot()],
exclude: [/(node_modules)/, ...Object.keys(virtualModules)],
enforce: 'post',
use: {
// we use our own patch because we need to remove tracing from the original code
// which is not possible otherwise
loader: require.resolve('./swc/next-swc-loader-patch.js'),
options: {
isServer: false,
rootDir: dir,
pagesDir: `${dir}/pages`,
appDir: `${dir}/apps`,
hasReactRefresh: isDevelopment,
jsConfig,
nextConfig,
supportedBrowsers: require('next/dist/build/utils').getSupportedBrowsers(
dir,
isDevelopment
),
swcCacheDir: path.join(dir, nextConfig?.distDir ?? '.next', 'cache', 'swc'),
bundleTarget: 'default',
},
},
];
});
};
8 changes: 5 additions & 3 deletions code/frameworks/nextjs/src/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,15 @@ import type {
BuilderOptions,
TypescriptOptions as TypescriptOptionsBuilder,
} from '@storybook/builder-webpack5';
import type { CompatibleString } from '@storybook/types';
import type * as NextImage from 'next/image';

type FrameworkName = '@storybook/nextjs';
type BuilderName = '@storybook/builder-webpack5';
type FrameworkName = CompatibleString<'@storybook/nextjs'>;
type BuilderName = CompatibleString<'@storybook/builder-webpack5'>;

export type FrameworkOptions = ReactOptions & {
nextConfigPath?: string;

image?: Partial<NextImage.ImageProps>;
builder?: BuilderOptions;
};

Expand Down
3 changes: 2 additions & 1 deletion code/frameworks/preact-vite/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,8 @@
},
"dependencies": {
"@storybook/builder-vite": "workspace:*",
"@storybook/preact": "workspace:*"
"@storybook/preact": "workspace:*",
"@storybook/types": "workspace:*"
},
"devDependencies": {
"@types/node": "^18.0.0",
Expand Down
6 changes: 3 additions & 3 deletions code/frameworks/preact-vite/src/types.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import type { StorybookConfig as StorybookConfigBase } from '@storybook/types';
import type { CompatibleString, StorybookConfig as StorybookConfigBase } from '@storybook/types';
import type { StorybookConfigVite, BuilderOptions } from '@storybook/builder-vite';

type FrameworkName = '@storybook/preact-vite';
type BuilderName = '@storybook/builder-vite';
type FrameworkName = CompatibleString<'@storybook/preact-vite'>;
type BuilderName = CompatibleString<'@storybook/builder-vite'>;

export type FrameworkOptions = {
builder?: BuilderOptions;
Expand Down
1 change: 1 addition & 0 deletions code/frameworks/preact-webpack5/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@
"@storybook/core-common": "workspace:*",
"@storybook/preact": "workspace:*",
"@storybook/preset-preact-webpack": "workspace:*",
"@storybook/types": "workspace:*",
"@types/node": "^18.0.0"
},
"devDependencies": {
Expand Down
5 changes: 3 additions & 2 deletions code/frameworks/preact-webpack5/src/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,10 @@ import type {
BuilderOptions,
TypescriptOptions as TypescriptOptionsBuilder,
} from '@storybook/builder-webpack5';
import type { CompatibleString } from '@storybook/types';

type FrameworkName = '@storybook/preact-webpack5';
type BuilderName = '@storybook/builder-webpack5';
type FrameworkName = CompatibleString<'@storybook/preact-webpack5'>;
type BuilderName = CompatibleString<'@storybook/builder-webpack5'>;

export type FrameworkOptions = {
builder?: BuilderOptions;
Expand Down
1 change: 1 addition & 0 deletions code/frameworks/react-vite/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@
"@storybook/builder-vite": "workspace:*",
"@storybook/node-logger": "workspace:*",
"@storybook/react": "workspace:*",
"@storybook/types": "workspace:*",
"find-up": "^5.0.0",
"magic-string": "^0.30.0",
"react-docgen": "^7.0.0",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,8 @@ import { utils } from 'react-docgen';
const { getNameOrValue, isReactForwardRefCall } = utils;

const actualNameHandler: Handler = function actualNameHandler(documentation, componentDefinition) {
documentation.set('definedInFile', componentDefinition.hub.file.opts.filename);

if (
(componentDefinition.isClassDeclaration() || componentDefinition.isFunctionDeclaration()) &&
componentDefinition.has('id')
Expand Down
6 changes: 3 additions & 3 deletions code/frameworks/react-vite/src/plugins/react-docgen.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ import {
} from './docgen-resolver';
import { logger } from '@storybook/node-logger';

type DocObj = Documentation & { actualName: string };
type DocObj = Documentation & { actualName: string; definedInFile: string };

// TODO: None of these are able to be overridden, so `default` is aspirational here.
const defaultHandlers = Object.values(docgenHandlers).map((handler) => handler);
Expand Down Expand Up @@ -71,8 +71,8 @@ export async function reactDocgen({
const s = new MagicString(src);

docgenResults.forEach((info) => {
const { actualName, ...docgenInfo } = info;
if (actualName) {
const { actualName, definedInFile, ...docgenInfo } = info;
if (actualName && definedInFile == id) {
const docNode = JSON.stringify(docgenInfo);
s.append(`;${actualName}.__docgenInfo=${docNode}`);
}
Expand Down
5 changes: 3 additions & 2 deletions code/frameworks/react-vite/src/types.ts
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
import type {
CompatibleString,
StorybookConfig as StorybookConfigBase,
TypescriptOptions as TypescriptOptionsBase,
} from '@storybook/types';
import type { StorybookConfigVite, BuilderOptions } from '@storybook/builder-vite';
import type docgenTypescript from '@joshwooding/vite-plugin-react-docgen-typescript';

type FrameworkName = '@storybook/react-vite';
type BuilderName = '@storybook/builder-vite';
type FrameworkName = CompatibleString<'@storybook/react-vite'>;
type BuilderName = CompatibleString<'@storybook/builder-vite'>;

export type FrameworkOptions = {
builder?: BuilderOptions;
Expand Down
1 change: 1 addition & 0 deletions code/frameworks/react-webpack5/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@
"@storybook/builder-webpack5": "workspace:*",
"@storybook/preset-react-webpack": "workspace:*",
"@storybook/react": "workspace:*",
"@storybook/types": "workspace:*",
"@types/node": "^18.0.0"
},
"peerDependencies": {
Expand Down
5 changes: 3 additions & 2 deletions code/frameworks/react-webpack5/src/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,10 @@ import type {
BuilderOptions,
TypescriptOptions as TypescriptOptionsBuilder,
} from '@storybook/builder-webpack5';
import type { CompatibleString } from '@storybook/types';

type FrameworkName = '@storybook/react-webpack5';
type BuilderName = '@storybook/builder-webpack5';
type FrameworkName = CompatibleString<'@storybook/react-webpack5'>;
type BuilderName = CompatibleString<'@storybook/builder-webpack5'>;

export type FrameworkOptions = ReactOptions & {
builder?: BuilderOptions;
Expand Down
1 change: 1 addition & 0 deletions code/frameworks/server-webpack5/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@
"@storybook/core-common": "workspace:*",
"@storybook/preset-server-webpack": "workspace:*",
"@storybook/server": "workspace:*",
"@storybook/types": "workspace:*",
"@types/node": "^18.0.0"
},
"devDependencies": {
Expand Down
5 changes: 3 additions & 2 deletions code/frameworks/server-webpack5/src/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,10 @@ import type {
BuilderOptions,
TypescriptOptions as TypescriptOptionsBuilder,
} from '@storybook/builder-webpack5';
import type { CompatibleString } from '@storybook/types';

type FrameworkName = '@storybook/server-webpack5';
type BuilderName = '@storybook/builder-webpack5';
type FrameworkName = CompatibleString<'@storybook/server-webpack5'>;
type BuilderName = CompatibleString<'@storybook/builder-webpack5'>;

export type FrameworkOptions = {
builder?: BuilderOptions;
Expand Down
1 change: 1 addition & 0 deletions code/frameworks/svelte-vite/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@
"@storybook/builder-vite": "workspace:*",
"@storybook/node-logger": "workspace:*",
"@storybook/svelte": "workspace:*",
"@storybook/types": "workspace:*",
"magic-string": "^0.30.0",
"svelte-preprocess": "^5.1.1",
"sveltedoc-parser": "^4.2.1",
Expand Down
6 changes: 3 additions & 3 deletions code/frameworks/svelte-vite/src/types.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import type { StorybookConfig as StorybookConfigBase } from '@storybook/types';
import type { CompatibleString, StorybookConfig as StorybookConfigBase } from '@storybook/types';
import type { StorybookConfigVite, BuilderOptions } from '@storybook/builder-vite';

type FrameworkName = '@storybook/svelte-vite';
type BuilderName = '@storybook/builder-vite';
type FrameworkName = CompatibleString<'@storybook/svelte-vite'>;
type BuilderName = CompatibleString<'@storybook/builder-vite'>;

export type FrameworkOptions = {
builder?: BuilderOptions;
Expand Down
Loading