Skip to content

Experimentation #31995

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

Closed
wants to merge 356 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
356 commits
Select commit Hold shift + click to select a range
5d3597f
simplify preset autoloading
JReinhold Jun 23, 2025
d014bf5
upgrade jiti in scripts
JReinhold Jun 23, 2025
53e251a
Merge pull request #31843 from storybookjs/norbert/test-esm-preset-addon
ndelangen Jun 23, 2025
5efb5b7
fix getModulePackageJSON usage
JReinhold Jun 23, 2025
f680c2f
remove __dirname from common
JReinhold Jun 23, 2025
074f17c
add "internal/core-server/presets/common-override-preset" as an export
JReinhold Jun 23, 2025
b07bc1a
sort exports, so it's easier to view changes
ndelangen Jun 23, 2025
47d072a
Merge branch 'sb10/esm-only' into jeppe/esm-core-scripts
ndelangen Jun 23, 2025
82b295b
Merge branch 'jeppe/esm-core-scripts' into jeppe/migrate-core-esm-only-2
ndelangen Jun 23, 2025
c99e34e
sort it better
ndelangen Jun 23, 2025
820a971
better sorting
ndelangen Jun 23, 2025
63d21cf
Merge branch 'sb10/esm-only' into jeppe/esm-core-scripts
ndelangen Jun 23, 2025
625c6ac
Merge branch 'jeppe/esm-core-scripts' into jeppe/migrate-core-esm-only-2
ndelangen Jun 23, 2025
7737d65
Merge branch 'jeppe/migrate-core-esm-only-2' into jeppe/migrate-core-…
ndelangen Jun 23, 2025
57cd8fe
Merge branch 'jeppe/migrate-core-esm-only-2' into jeppe/migrate-core-…
ndelangen Jun 23, 2025
b395414
Refactor common-preset to use dirname for resolved React and ReactDOM…
ndelangen Jun 23, 2025
0ad8fc9
Fix async handling in getIncompatibleStorybookPackages by awaiting pa…
ndelangen Jun 23, 2025
cb176b4
Update tests to handle async responses from getModulePackageJSON in d…
ndelangen Jun 23, 2025
52d432b
fix preset unit tests, replace interopRequireDefault with importModule
JReinhold Jun 24, 2025
bac0bef
Merge branch 'jeppe/migrate-core-esm-only-4' of github.com:storybookj…
JReinhold Jun 24, 2025
274c881
rename resolve util to module
JReinhold Jun 24, 2025
13f2fd3
Update extraDevDeps in sandbox-parts to use the latest canary version…
ndelangen Jun 24, 2025
6cbf1ee
Merge branch 'jeppe/migrate-core-esm-only-4' of https://github.com/st…
ndelangen Jun 24, 2025
62c1f5e
Merge branch 'jeppe/migrate-core-esm-only-3' into jeppe/migrate-core-…
ndelangen Jun 24, 2025
b230a11
fix template tests
JReinhold Jun 24, 2025
94b1a20
Merge branch 'jeppe/migrate-core-esm-only-4' of github.com:storybookj…
JReinhold Jun 24, 2025
c1a6195
Merge pull request #31824 from storybookjs/jeppe/migrate-core-esm-only-2
ndelangen Jun 24, 2025
abda48f
Merge branch 'jeppe/esm-core-scripts' into jeppe/migrate-core-esm-only-3
ndelangen Jun 24, 2025
d1b6ba7
cleanup
JReinhold Jun 24, 2025
af3dcb7
Update peer dependencies to support Vite version 7.0.0 across various…
ndelangen Jun 24, 2025
ae8a741
Merge branch 'jeppe/migrate-core-esm-only-4' of https://github.com/st…
ndelangen Jun 24, 2025
3ef90be
Merge branch 'jeppe/migrate-core-esm-only-3' into jeppe/migrate-core-…
ndelangen Jun 24, 2025
4f972d2
Enable Jest tests in CircleCI configuration and add SWC configuration…
ndelangen Jun 24, 2025
5db06ac
migrate core CLI to ESM
JReinhold Jun 24, 2025
2093197
fix core cli reference in tests
JReinhold Jun 24, 2025
f1cf4e1
update lock file
JReinhold Jun 24, 2025
d4b7870
Merge pull request #31821 from storybookjs/jeppe/esm-core-scripts
JReinhold Jun 24, 2025
00f6a70
Merge branch 'sb10/esm-only' into jeppe/migrate-core-esm-only-3
JReinhold Jun 24, 2025
fdacd10
Merge branch 'jeppe/migrate-core-esm-only-3' into jeppe/migrate-core-…
JReinhold Jun 24, 2025
6d57e5f
fix types
JReinhold Jun 24, 2025
fad3dfe
Update extra development dependencies in sandbox-parts.ts to the late…
ndelangen Jun 24, 2025
cb2648f
Merge branch 'jeppe/migrate-core-esm-only-4' of https://github.com/st…
ndelangen Jun 24, 2025
8618efb
Merge branch 'next' into sb10/esm-only
ndelangen Jun 24, 2025
72caa47
Merge branch 'sb10/esm-only' into jeppe/migrate-core-esm-only-3
ndelangen Jun 24, 2025
b06aecc
Merge branch 'jeppe/migrate-core-esm-only-3' into jeppe/migrate-core-…
ndelangen Jun 24, 2025
b3c6ebd
Merge pull request #31831 from storybookjs/jeppe/migrate-core-esm-only-4
ndelangen Jun 24, 2025
f7525c7
use pathe in module util
JReinhold Jun 25, 2025
20a5b84
Merge branch 'jeppe/migrate-core-esm-only-3' into jeppe/migrate-core-…
JReinhold Jun 25, 2025
5261564
replace node:path with pathe
JReinhold Jun 25, 2025
6b62258
ESM-only-fi core scripts, upgrade jiti
JReinhold Jun 25, 2025
aaa8b14
cleanup
JReinhold Jun 25, 2025
01f93a2
cleanup
JReinhold Jun 25, 2025
83c7b59
replace serverRequire with resolveSync + importModule
JReinhold Jun 25, 2025
fbd2e80
try pathToFileUrl first
JReinhold Jun 25, 2025
e009a86
use pathToFileURL from node:url
JReinhold Jun 25, 2025
f3d823f
Update package.json to reference CommonJS entry point and add index.c…
ndelangen Jun 25, 2025
b74366d
add empty catch to bin delegator
JReinhold Jun 25, 2025
4a771d5
Merge branch 'jeppe/migrate-core-esm-only-3' into jeppe/migrate-core-…
ndelangen Jun 25, 2025
5f1d143
try resolve from node:path instead
JReinhold Jun 25, 2025
2690f6c
Update yarn.lock to reference CommonJS entry point for Storybook CLI
ndelangen Jun 25, 2025
4b6fcc7
Merge branch 'jeppe/migrate-core-esm-only-5' of https://github.com/st…
ndelangen Jun 25, 2025
b8c61c0
Merge branch 'jeppe/migrate-core-esm-only-3' into jeppe/migrate-core-…
ndelangen Jun 25, 2025
365b003
use serverResolve instead of resolveSync
JReinhold Jun 25, 2025
0d3c5e7
remove esm-only main error
JReinhold Jun 25, 2025
b81e360
Update package.json to use CommonJS entry point for Storybook CLI by …
ndelangen Jun 25, 2025
8ca9b81
Merge branch 'next' into sb10/esm-only
ndelangen Jun 25, 2025
a82a318
Merge branch 'sb10/esm-only' into jeppe/migrate-core-esm-only-3
ndelangen Jun 25, 2025
9291da0
Merge branch 'jeppe/migrate-core-esm-only-3' into jeppe/migrate-core-…
ndelangen Jun 25, 2025
6b2209b
Merge branch 'next' into sb10/esm-only
ndelangen Jun 25, 2025
25dec6c
Merge branch 'sb10/esm-only' into jeppe/migrate-core-esm-only-3
ndelangen Jun 25, 2025
98b0043
Merge branch 'jeppe/migrate-core-esm-only-3' into jeppe/migrate-core-…
ndelangen Jun 25, 2025
f64f7c6
logs everywhere
JReinhold Jun 25, 2025
8db2b21
Merge branch 'jeppe/migrate-core-esm-only-3' of github.com:storybookj…
JReinhold Jun 25, 2025
307eb5a
convert to fileURL when registering ts-loader
JReinhold Jun 25, 2025
9cf55ae
simplify serverRequire/serverResolve, convert absolute win32 paths to…
JReinhold Jun 25, 2025
7d30042
cleanup console logs
JReinhold Jun 25, 2025
e079813
more console.log cleanup
JReinhold Jun 25, 2025
534b230
Remove `typesVersions` field from `package.json` and update `generate…
ndelangen Jun 25, 2025
1ec4480
Remove `typesVersions` field from multiple `package.json` files to st…
ndelangen Jun 25, 2025
b6497df
add logs to favicon test
JReinhold Jun 26, 2025
bb19bf3
focus windows tests
JReinhold Jun 26, 2025
84f9214
use pathe in favicon tests
JReinhold Jun 26, 2025
fb6f1c7
minimize usage of pathe
JReinhold Jun 26, 2025
c595e2c
Only support ESM version of getAbsolutePath
ndelangen Jun 26, 2025
f1a0e6e
move error to consolidated errors file
ndelangen Jun 26, 2025
b1df402
rename further references to wrapRequire tro wrapGetAbsolutePath
ndelangen Jun 26, 2025
4716372
Refactor getAbsolutePath wrapper references to use constants for pref…
ndelangen Jun 26, 2025
028ab15
remove temporary unit test debugging, add yarn caching to windows uni…
JReinhold Jun 26, 2025
affaace
Rename function references from `getFieldsForgetAbsolutePathWrapper` …
ndelangen Jun 26, 2025
5f21c9d
Merge branch 'jeppe/migrate-core-esm-only-3' into jeppe/migrate-core-…
JReinhold Jun 26, 2025
c53649d
Merge branch 'jeppe/migrate-core-esm-only-5' into norbert/no-typesver…
JReinhold Jun 26, 2025
78697eb
fix unit tests
JReinhold Jun 26, 2025
49faa9c
Merge branch 'jeppe/migrate-core-esm-only-5' of github.com:storybookj…
JReinhold Jun 26, 2025
ad97fcb
rename core bins
JReinhold Jun 26, 2025
bd9ece7
simplify child exit handling
JReinhold Jun 27, 2025
32772e9
remove index.cjs, use dispatcher directly instead
JReinhold Jun 27, 2025
ef28812
update lock file
JReinhold Jun 27, 2025
038f74f
add migration note about node version
JReinhold Jun 27, 2025
e4562fd
fix CLI tests
JReinhold Jun 27, 2025
9e3ffe7
Merge branch 'jeppe/migrate-core-esm-only-5' into norbert/no-typesver…
ndelangen Jun 27, 2025
32f39df
Add migration note for TypeScript `moduleResolution` requirement in S…
ndelangen Jun 27, 2025
5a8ebe2
Merge branch 'jeppe/migrate-core-esm-only-5' into norbert/no-typesver…
ndelangen Jun 27, 2025
0506241
Update docs/_snippets/storybook-main-pnpm-with-module-resolution.md
ndelangen Jun 27, 2025
7dd5dd6
Merge branch 'norbert/no-typesversions' into norbert/no-getabsolutepath
ndelangen Jun 27, 2025
369e673
Merge branch 'next' into sb10/esm-only
ndelangen Jun 27, 2025
824a900
replace resolveModule with simpler resolvePackageDir and importMetaRe…
JReinhold Jun 27, 2025
7504fe1
Update package.json to simplify NODE_OPTIONS for Storybook commands
ndelangen Jun 27, 2025
f3753a6
cleanup
JReinhold Jun 27, 2025
67f2eac
Merge pull request #31825 from storybookjs/jeppe/migrate-core-esm-only-3
JReinhold Jun 27, 2025
fda1178
Merge branch 'sb10/esm-only' into norbert/delete-symlink-node-flags-m…
JReinhold Jun 27, 2025
8d85002
add backwards compatibility for builders defined as an absolute path …
ndelangen Jun 27, 2025
6dd6ad1
Merge pull request #31860 from storybookjs/jeppe/migrate-core-esm-only-5
ndelangen Jun 27, 2025
32b5673
Merge pull request #31872 from storybookjs/norbert/no-typesversions
ndelangen Jun 27, 2025
6f3cb9b
Merge pull request #31875 from storybookjs/norbert/no-getabsolutepath
ndelangen Jun 27, 2025
6a6cc3c
Merge branch 'next' into norbert/delete-symlink-node-flags-monorepo
ndelangen Jun 27, 2025
d52f50a
Merge branch 'sb10/esm-only' into norbert/delete-symlink-node-flags-m…
ndelangen Jun 27, 2025
8b752a7
Merge pull request #31892 from storybookjs/norbert/delete-symlink-nod…
ndelangen Jun 27, 2025
2578e74
Merge branch 'sb10/esm-only' of github.com:storybookjs/storybook into…
JReinhold Jun 30, 2025
7da70bc
cleanup
JReinhold Jun 30, 2025
c53ec25
remove old entries
JReinhold Jun 30, 2025
40ddef4
rename all esmOnlyX to x, remove unused configs
JReinhold Jun 30, 2025
77dc804
cleanup
JReinhold Jun 30, 2025
c1325be
Merge pull request #31905 from storybookjs/jeppe/simplify-module-reso…
JReinhold Jun 30, 2025
c858fe5
Merge branch 'sb10/esm-only' into jeppe/cleanup-core-scripts
ndelangen Jun 30, 2025
5212f95
Merge pull request #31907 from storybookjs/jeppe/cleanup-core-scripts
ndelangen Jun 30, 2025
5e93de4
move stuff from core to scripts
JReinhold Jun 30, 2025
bdc4d9d
Refactor build process: Introduce postbuild step for setting executab…
ndelangen Jun 30, 2025
813ecbb
Merge branch 'next' into sb10/esm-only
ndelangen Jul 1, 2025
5ab19ed
migrate dts bundling to generalized tooling
JReinhold Jul 1, 2025
235f0dc
Merge branch 'sb10/esm-only' of github.com:storybookjs/storybook into…
JReinhold Jul 1, 2025
9d653ef
esm-only-fi create-storybook
JReinhold Jul 1, 2025
c1e6940
remove build scripts from core
JReinhold Jul 1, 2025
5cd8bb0
Refactor: Rename applyAddonRequireWrapper to applyAddonGetAbsolutePat…
ndelangen Jul 1, 2025
51f7631
Merge branch 'next' into sb10/esm-only
ndelangen Jul 1, 2025
39c5eea
Merge branch 'sb10/esm-only' into jeppe/generalize-core-scripts
ndelangen Jul 1, 2025
24b9379
Refactor: Separate create-storybook CLI logic into run.ts and update …
ndelangen Jul 1, 2025
51f50c9
Refactor: Update CLI structure by removing index.cjs, consolidating l…
ndelangen Jul 1, 2025
9f9f3f7
Refactor: Update Node.js version requirements in package.json and imp…
ndelangen Jul 1, 2025
3846930
Refactor: Update build scripts to use exec for prebuild tasks, improv…
ndelangen Jul 1, 2025
dfcec89
Refactor: Consolidate build utilities and enhance type generation log…
ndelangen Jul 1, 2025
9a23965
bust nx cache
ndelangen Jul 1, 2025
3e77220
bust nx cache
ndelangen Jul 1, 2025
5673fa2
Refactor: Simplify package.json reading in check.ts and update cli-st…
ndelangen Jul 1, 2025
f08a42c
Refactor: Update package.json path references in webpack5 builder and…
ndelangen Jul 1, 2025
264da8e
Refactor: Update dispatcher to use the correct path for CLI entry poi…
ndelangen Jul 1, 2025
0f3e165
undo cache busting
ndelangen Jul 1, 2025
69bc594
Refactor: Remove error handling from CLI entry point in index.ts by s…
ndelangen Jul 1, 2025
2d2a451
Refactor: Enhance build entry handling by introducing type guards for…
ndelangen Jul 1, 2025
3d59895
Refactor: Streamline the build process by consolidating the measureme…
ndelangen Jul 1, 2025
2fb3230
Merge branch 'next' into sb10/esm-only
ndelangen Jul 1, 2025
ef1a815
Merge branch 'sb10/esm-only' into jeppe/generalize-core-scripts
ndelangen Jul 1, 2025
351faaa
bust cache
ndelangen Jul 1, 2025
523bf3e
Merge branch 'jeppe/generalize-core-scripts' of https://github.com/st…
ndelangen Jul 1, 2025
044414a
Refactor: Update favicon wrapper path resolution to use resolvePackag…
ndelangen Jul 1, 2025
1e005c1
chore: Add shebang to CLI entry point for improved script execution
ndelangen Jul 1, 2025
5e6ea54
feat: Add postbuild step to set executable permissions for bin scripts
ndelangen Jul 1, 2025
6a00c6c
refactor: Simplify chmod calls in postbuild steps by removing interme…
ndelangen Jul 1, 2025
e814880
chore: Update CircleCI config to streamline Storybook initialization …
ndelangen Jul 1, 2025
5b0fdeb
chore: Add NPM version check and adjust Storybook initialization path…
ndelangen Jul 2, 2025
ea2e1bd
chore: Update CircleCI config to set global NPM registry and correct …
ndelangen Jul 2, 2025
e9e1259
chore: Remove unnecessary prep step and update Storybook initializati…
ndelangen Jul 2, 2025
cee5460
chore: Refactor CircleCI config to adjust Storybook initialization pa…
ndelangen Jul 2, 2025
649f55b
chore: Update CircleCI config to create features-1 directory before S…
ndelangen Jul 2, 2025
64822d4
chore: Enhance CircleCI config by adding wait-on for additional Story…
ndelangen Jul 2, 2025
2ef35df
chore: Update CircleCI config to enhance curl commands for Storybook …
ndelangen Jul 2, 2025
25f9f76
mock out import.meta.resolve in all internal unit tests
JReinhold Jul 2, 2025
4cf7f72
Merge branch 'jeppe/generalize-core-scripts' of github.com:storybookj…
JReinhold Jul 2, 2025
00aff67
refactor: Update prompt import path in prompt-provider-prompts.ts and…
ndelangen Jul 2, 2025
0ac6b3e
upgrade CI to node 22.16
JReinhold Jul 2, 2025
49d13be
Merge branch 'jeppe/generalize-core-scripts' of github.com:storybookj…
JReinhold Jul 2, 2025
b40359d
install node 22.16.0
JReinhold Jul 2, 2025
f8a1860
chore: Update Node.js engine requirement to >=22.0.0 across all packa…
ndelangen Jul 2, 2025
a0fdc3f
revert back to node 22.15 in ci
JReinhold Jul 2, 2025
9a750c5
Merge branches 'jeppe/generalize-core-scripts' and 'jeppe/generalize-…
JReinhold Jul 2, 2025
261482a
remove unnecessary @ts-ignore-error
JReinhold Jul 2, 2025
fc81c5f
chore: Standardize Node.js version syntax in CircleCI config and remo…
ndelangen Jul 2, 2025
8da65f3
cleanup
JReinhold Jul 2, 2025
5f273f3
Merge branch 'jeppe/generalize-core-scripts' of https://github.com/st…
ndelangen Jul 2, 2025
a5b2c82
Merge branch 'jeppe/generalize-core-scripts' of https://github.com/st…
ndelangen Jul 2, 2025
14575dc
improve scripts file naming
JReinhold Jul 2, 2025
d246de3
Merge branch 'jeppe/generalize-core-scripts' of github.com:storybookj…
JReinhold Jul 2, 2025
7b30bf3
change storybook/cli usage of require to import
JReinhold Jul 2, 2025
42ebcaf
enable code splitting, undo create-storybook types
JReinhold Jul 2, 2025
4bf2f61
Enhance metafile handling in build scripts and add error handling for…
ndelangen Jul 2, 2025
be71ba3
Merge branch 'jeppe/generalize-core-scripts' of https://github.com/st…
ndelangen Jul 2, 2025
46ef997
Merge branch 'next' into sb10/esm-only
ndelangen Jul 2, 2025
0af1a95
Merge branch 'sb10/esm-only' into jeppe/generalize-core-scripts
ndelangen Jul 2, 2025
8e9ef53
move the check script out of code/core
ndelangen Jul 2, 2025
f0d76b3
update check script path in package.json for cli-storybook and create…
ndelangen Jul 2, 2025
1facb42
only enable splitting for 'node' and 'browser' entries
JReinhold Jul 2, 2025
430f68d
Merge branch 'jeppe/generalize-core-scripts' of github.com:storybookj…
JReinhold Jul 2, 2025
94e5eb8
update check script path in package.json files across multiple addons…
ndelangen Jul 2, 2025
5d8a6a3
Merge branch 'jeppe/generalize-core-scripts' of https://github.com/st…
ndelangen Jul 2, 2025
53e2b34
Remove @happy-dom/global-registrator dependency from package.json and…
ndelangen Jul 2, 2025
a90648e
Remove types.json metafile from esbuild metafiles directory
ndelangen Jul 2, 2025
1616818
disable nuxt sandbox temporarily
JReinhold Jul 2, 2025
1ce2822
Merge branch 'jeppe/generalize-core-scripts' of github.com:storybookj…
JReinhold Jul 2, 2025
3d328fe
undo cache busting
ndelangen Jul 2, 2025
282c4bf
Merge branch 'jeppe/generalize-core-scripts' of https://github.com/st…
ndelangen Jul 2, 2025
5c17296
add comments detailing differences between the 2 identically named files
ndelangen Jul 2, 2025
efdf01c
rename
ndelangen Jul 2, 2025
b27d6e6
Refactor build scripts to import tools directly and streamline depend…
ndelangen Jul 2, 2025
331b3b8
Add artifact storage configuration for CircleCI to store sandbox feat…
ndelangen Jul 2, 2025
173c49b
Add command to create a zip archive of features and update artifact s…
ndelangen Jul 2, 2025
e095256
Update CircleCI configuration to create a zip archive of features and…
ndelangen Jul 2, 2025
bb477f7
Update CircleCI configuration to create a tar archive of features and…
ndelangen Jul 2, 2025
da8f654
Update CircleCI configuration to create a tar archive of features-1 a…
ndelangen Jul 2, 2025
a118415
Fix command in CircleCI configuration to use 'cd' instead of 'cs' for…
ndelangen Jul 2, 2025
c18b4a5
Refactor postinstallAddon to use importModule for dynamic imports and…
ndelangen Jul 2, 2025
c2f14c1
Enhance postinstallAddon to improve error handling and ensure postins…
ndelangen Jul 2, 2025
721866f
Refactor postinstallAddon to improve module resolution and error hand…
ndelangen Jul 2, 2025
b1a68a2
Enhance postinstallAddon by adding fallback require statements for im…
ndelangen Jul 2, 2025
e76bd3e
Improve error logging in postinstallAddon by adding a console message…
ndelangen Jul 2, 2025
a522dce
Refactor postinstallAddon to use process.cwd() for consistent module …
ndelangen Jul 2, 2025
e8c98ad
Refactor postinstallAddon to streamline module resolution by removing…
ndelangen Jul 2, 2025
2c7976b
Refactor module.ts to remove unnecessary imports and streamline path …
ndelangen Jul 2, 2025
42e2133
Enhance generateBundle function by adding legalComments and ignoreAnn…
ndelangen Jul 2, 2025
81448a3
cache bust
ndelangen Jul 2, 2025
6e0b71d
try to fix importMetaResolve mock on windows
JReinhold Jul 3, 2025
76a3cec
Merge branch 'jeppe/generalize-core-scripts' of github.com:storybookj…
JReinhold Jul 3, 2025
53a364e
Merge branch 'next' into sb10/esm-only
ndelangen Jul 3, 2025
8e4232c
Merge branch 'sb10/esm-only' into jeppe/generalize-core-scripts
ndelangen Jul 3, 2025
f633164
Add optimization for esbuild metafile to include only used inputs
ndelangen Jul 3, 2025
b2da4db
Remove debug logging from postinstallAddon for cleaner output
ndelangen Jul 3, 2025
dff3e61
Merge branch 'next' into sb10/esm-only
JReinhold Jul 4, 2025
f6e5619
Merge branch 'sb10/esm-only' into jeppe/generalize-core-scripts
JReinhold Jul 4, 2025
1d853df
Refactor generateBundle function to improve context handling and remo…
ndelangen Jul 4, 2025
845f332
Refactor generateBundle function to filter out falsy contexts and str…
ndelangen Jul 4, 2025
a580a63
Update generateBundle function to remove existing metafile directory …
ndelangen Jul 4, 2025
4998879
Remove debug logging for metafile removal in generateBundle function …
ndelangen Jul 4, 2025
04c33a1
Merge pull request #31917 from storybookjs/jeppe/generalize-core-scripts
ndelangen Jul 4, 2025
6f5403c
simplify Yarn PnP API usage
JReinhold Jul 4, 2025
d67278b
dont convert preview builder paths before importing
JReinhold Jul 4, 2025
6f9b0ae
use yarn pnp compatible resolutions
JReinhold Jul 7, 2025
f19343b
add Yarn PnP test storybook
JReinhold Jul 7, 2025
a457a43
add Yarn PnP test to Circle config
JReinhold Jul 7, 2025
9590730
revert simplifed yarn pnp api usage.
JReinhold Jul 7, 2025
b29ae7f
upgrade to latest node 22 in ci
JReinhold Jul 7, 2025
7e7acf0
Merge branch 'next' into sb10/esm-only
ndelangen Jul 7, 2025
3220636
use node orb
JReinhold Jul 7, 2025
7058a6f
fix playwright versions
JReinhold Jul 7, 2025
8bb19ec
remove node version step
JReinhold Jul 7, 2025
08edd38
Merge branch 'next' into sb10/esm-only
ndelangen Jul 7, 2025
9b9ae7b
Update extra development dependencies in sandbox-parts.ts to latest c…
ndelangen Jul 7, 2025
4759589
fix safe resolution in resolveAddonName
JReinhold Jul 8, 2025
d4ec962
add playwright dep to pnp project
JReinhold Jul 8, 2025
4889efd
Merge pull request #31968 from storybookjs/jeppe/fix-yarn-pnp
JReinhold Jul 8, 2025
f314fae
Increase timeout duration in generateTypesFiles function from 60 seco…
ndelangen Jul 9, 2025
6f08cc5
Merge branch 'next' into sb10/esm-only
ndelangen Jul 9, 2025
ffcd639
update test-runner version
yannbf Jul 9, 2025
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
197 changes: 128 additions & 69 deletions .circleci/config.yml

Large diffs are not rendered by default.

20 changes: 13 additions & 7 deletions .github/workflows/canary-release-pr.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
name: Publish canary release of PR
run-name: "Canary release: PR #${{ inputs.pr }}, triggered by ${{ github.triggering_actor }}"
run-name: "Canary release: PR #${{ github.event_name == 'workflow_dispatch' && inputs.pr || github.event.pull_request.number }}, triggered by ${{ github.triggering_actor }}"

on:
workflow_dispatch:
Expand All @@ -8,13 +8,15 @@ on:
description: "Pull request number to create a canary release for"
required: true
type: number
pull_request:
types: [opened, synchronize, reopened]

env:
PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD: 1
PUPPETEER_SKIP_CHROMIUM_DOWNLOAD: 1

concurrency:
group: ${{ github.workflow }}-${{ github.event.inputs.pr }}
group: ${{ github.workflow }}-${{ github.event_name == 'workflow_dispatch' && inputs.pr || github.event.pull_request.number }}
cancel-in-progress: true

permissions:
Expand All @@ -25,6 +27,7 @@ jobs:
name: Release canary version
runs-on: ubuntu-latest
environment: release
if: github.event_name == 'workflow_dispatch' || github.head_ref == 'sb10/esm-only'
steps:
- name: Fail if triggering actor is not administrator
uses: prince-chrismc/[email protected]
Expand All @@ -36,7 +39,8 @@ jobs:
env:
GH_TOKEN: ${{ secrets.GH_TOKEN }}
run: |
PR_INFO=$(gh pr view ${{ inputs.pr }} --repo ${{ github.repository }} --json isCrossRepository,headRefOid,headRefName,headRepository,headRepositoryOwner --jq '{isFork: .isCrossRepository, owner: .headRepositoryOwner.login, repoName: .headRepository.name, branch: .headRefName, sha: .headRefOid}')
PR_NUMBER=${{ github.event_name == 'workflow_dispatch' && inputs.pr || github.event.pull_request.number }}
PR_INFO=$(gh pr view $PR_NUMBER --repo ${{ github.repository }} --json isCrossRepository,headRefOid,headRefName,headRepository,headRepositoryOwner --jq '{isFork: .isCrossRepository, owner: .headRepositoryOwner.login, repoName: .headRepository.name, branch: .headRefName, sha: .headRefOid}')
echo $PR_INFO
# Loop through each key-value pair in PR_INFO and set as step output
for key in $(echo "$PR_INFO" | jq -r 'keys[]'); do
Expand Down Expand Up @@ -78,7 +82,8 @@ jobs:
id: version
working-directory: scripts
run: |
yarn release:version --exact 0.0.0-pr-${{ inputs.pr }}-sha-${{ steps.info.outputs.shortSha }} --verbose
PR_NUMBER=${{ github.event_name == 'workflow_dispatch' && inputs.pr || github.event.pull_request.number }}
yarn release:version --exact 0.0.0-pr-$PR_NUMBER-sha-${{ steps.info.outputs.shortSha }} --verbose

- name: Publish v${{ steps.version.outputs.next-version }}
env:
Expand All @@ -91,7 +96,7 @@ jobs:
uses: mcky/[email protected]
with:
githubToken: ${{ secrets.GH_TOKEN }}
prNumber: ${{ inputs.pr }}
prNumber: ${{ github.event_name == 'workflow_dispatch' && inputs.pr || '' }}
find: "CANARY_RELEASE_SECTION"
isHtmlCommentTag: true
replace: |
Expand All @@ -111,14 +116,15 @@ jobs:

To request a new release of this pull request, mention the `@storybookjs/core` team.

_core team members can create a new canary release [here](https://github.com/storybookjs/storybook/actions/workflows/canary-release-pr.yml) or locally with `gh workflow run --repo storybookjs/storybook canary-release-pr.yml --field pr=${{ inputs.pr }}`_
_core team members can create a new canary release [here](https://github.com/storybookjs/storybook/actions/workflows/canary-release-pr.yml) or locally with `gh workflow run --repo storybookjs/storybook canary-release-pr.yml --field pr=${{ github.event_name == 'workflow_dispatch' && inputs.pr || github.event.pull_request.number }}`_
</details>

- name: Create failing comment on PR
if: failure()
env:
GH_TOKEN: ${{ secrets.GH_TOKEN }}
run: |
gh pr comment ${{ inputs.pr }}\
PR_NUMBER=${{ github.event_name == 'workflow_dispatch' && inputs.pr || github.event.pull_request.number }}
gh pr comment $PR_NUMBER\
--repo "${{github.repository }}"\
--body "Failed to publish canary version of this pull request, triggered by @${{ github.triggering_actor }}. See the failed workflow run at: https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}"
6 changes: 4 additions & 2 deletions .github/workflows/tests-unit.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,6 @@ env:
jobs:
build:
name: Core Unit Tests, windows-latest
strategy:
fail-fast: false
runs-on: windows-11-arm
steps:
- uses: actions/checkout@v4
Expand All @@ -24,6 +22,10 @@ jobs:
uses: actions/setup-node@v4
with:
node-version-file: ".nvmrc"
cache: 'yarn'
cache-dependency-path: |
code/yarn.lock
scripts/yarn.lock

- name: install scripts
run: |
Expand Down
2 changes: 1 addition & 1 deletion .nvmrc
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
22.13.1
22.16.0

37 changes: 36 additions & 1 deletion MIGRATION.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
<h1>Migration</h1>

- [From version 9.x to 10.0.0](#from-version-9x-to-1000)
- [Core Changes](#core-changes)
- [Node.js 20.19+ or 22.12+ required](#nodejs-2019-or-2212-required)
- [Require `tsconfig.json` `moduleResolution` set to value that supports `types` condition](#require-tsconfigjson-moduleresolution-set-to-value-that-supports-types-condition)
- [From version 8.x to 9.0.0](#from-version-8x-to-900)
- [Core Changes and Removals](#core-changes-and-removals)
- [Dropped support for legacy packages](#dropped-support-for-legacy-packages)
Expand Down Expand Up @@ -97,7 +101,7 @@
- [MDX is upgraded to v3](#mdx-is-upgraded-to-v3)
- [Dropping support for \*.stories.mdx (CSF in MDX) format and MDX1 support](#dropping-support-for-storiesmdx-csf-in-mdx-format-and-mdx1-support)
- [Dropping support for id, name and story in Story block](#dropping-support-for-id-name-and-story-in-story-block)
- [Core changes](#core-changes)
- [Core changes](#core-changes-1)
- [`framework.options.builder.useSWC` for Webpack5-based projects removed](#frameworkoptionsbuilderuseswc-for-webpack5-based-projects-removed)
- [Removed `@babel/core` and `babel-loader` from `@storybook/builder-webpack5`](#removed-babelcore-and-babel-loader-from-storybookbuilder-webpack5)
- [`framework.options.fastRefresh` for Webpack5-based projects removed](#frameworkoptionsfastrefresh-for-webpack5-based-projects-removed)
Expand Down Expand Up @@ -477,6 +481,37 @@
- [Packages renaming](#packages-renaming)
- [Deprecated embedded addons](#deprecated-embedded-addons)

## From version 9.x to 10.0.0

### Core Changes

#### Node.js 20.19+ or 22.12+ required

Storybook 10 now requires Node.js version 20.19+ or 22.12+. We require these new ranges so Node.js supports `require(esm)` without a flag.

#### Require `tsconfig.json` `moduleResolution` set to value that supports `types` condition

Storybook 10 has removed all `typesVersions` fields from `package.json` files. This field was previously needed for older TypeScript module resolution strategies that didn't support the `types` condition in package.json exports.

**Required action:** Update your `tsconfig.json` to use a `moduleResolution` that supports the `types` condition:

```json
{
"compilerOptions": {
"moduleResolution": "bundler" // or "node16"/"nodenext"
}
}
```

**Supported values:**

- `"bundler"` (recommended for modern bundler-based projects)
- `"node16"` or `"nodenext"` (Node.js 16+ module resolution)

**Note:** If you're currently using `moduleResolution: "node"` (the old Node.js 10-style resolution), you'll need to upgrade to one of the supported values above.

This change simplifies our package structure and aligns with modern TypeScript standards. Only TypeScript projects are affected - JavaScript projects require no changes.

## From version 8.x to 9.0.0

### Core Changes and Removals
Expand Down
31 changes: 30 additions & 1 deletion code/.storybook/bench.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -35,10 +35,14 @@ export default {
labels: Object.fromEntries(
Object.keys(allMetafiles).map((path) => {
const [, dirName, subEntry] = /esbuild-metafiles\/(.+)\/(.+).json/.exec(path)!;
const pkgName = PACKAGES_WITHOUT_ORG.includes(dirName)
let pkgName = PACKAGES_WITHOUT_ORG.includes(dirName)
? dirName
: `@storybook/${dirName}`;

if (pkgName === '@storybook/core') {
pkgName = 'storybook';
}

return [
safeMetafileArg(path),
subEntry !== 'metafile' ? `${pkgName} - ${subEntry}` : pkgName,
Expand Down Expand Up @@ -66,6 +70,31 @@ export default {
render: (args, { loaded }) => {
const { encodedMetafile = '' } = loaded ?? {};

if (encodedMetafile.length > 2020836) {
return (
<div style={{ padding: '2rem' }}>
<h1>Metafile is too large</h1>
<p>
The metafile <code>{args.metafile}</code> is <strong>too large</strong> to be displayed
in the iframe. This is because we base64-encode the contents of the metafile into the
URL of the <code>{'<iframe />'}</code> component, and there's a maximum length of{' '}
<code>~2MB</code> for the URL.
</p>
<p>
You can visit the{' '}
<a href="https://esbuild.github.io/analyze/" target="_blank" rel="noreferrer">
esbuild analyzer website
</a>{' '}
manually to see the metafile.
</p>
<p>
You will have to find the metafile in the <code>code/bench/esbuild-metafiles</code>{' '}
directory and upload it manually.
</p>
</div>
);
}

return (
<iframe
// esbuild analyzer has a hidden feature to load a base64-encoded metafile from the the URL hash
Expand Down
1 change: 0 additions & 1 deletion code/addons/a11y/manager.js

This file was deleted.

25 changes: 5 additions & 20 deletions code/addons/a11y/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,35 +25,20 @@
"url": "https://opencollective.com/storybook"
},
"license": "MIT",
"type": "module",
"exports": {
".": {
"types": "./dist/index.d.ts",
"import": "./dist/index.mjs",
"require": "./dist/index.js"
"default": "./dist/index.js"
},
"./preview": {
"types": "./dist/preview.d.ts",
"import": "./dist/preview.mjs",
"require": "./dist/preview.js"
"default": "./dist/preview.js"
},
"./manager": "./dist/manager.js",
"./register": "./dist/manager.js",
"./package.json": "./package.json",
"./postinstall": "./dist/postinstall.js"
},
"main": "dist/index.js",
"module": "dist/index.mjs",
"types": "dist/index.d.ts",
"typesVersions": {
"*": {
"*": [
"dist/index.d.ts"
],
"preview": [
"dist/preview.d.ts"
]
}
},
"files": [
"dist/**/*",
"README.md",
Expand All @@ -62,7 +47,7 @@
"!src/**/*"
],
"scripts": {
"check": "jiti ../../../scripts/prepare/check.ts",
"check": "jiti ../../../scripts/check/check-package.ts",
"prep": "jiti ../../../scripts/prepare/addon-bundle.ts"
},
"dependencies": {
Expand Down Expand Up @@ -100,7 +85,7 @@
"./src/postinstall.ts"
]
},
"gitHead": "e6a7fd8a655c69780bc20b9749c2699e44beae16",
"gitHead": "e6e7fd8a655c69780bc20b9749c2699e44beae16",
"storybook": {
"displayName": "Accessibility",
"icon": "https://user-images.githubusercontent.com/263385/101991665-47042f80-3c7c-11eb-8f00-64b5a18f498a.png",
Expand Down
1 change: 0 additions & 1 deletion code/addons/a11y/preview.js

This file was deleted.

23 changes: 2 additions & 21 deletions code/addons/docs/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -70,25 +70,6 @@
"main": "dist/index.js",
"module": "dist/index.mjs",
"types": "dist/index.d.ts",
"typesVersions": {
"*": {
"*": [
"dist/index.d.ts"
],
"angular": [
"angular/index.d.ts"
],
"blocks": [
"dist/blocks.d.ts"
],
"ember": [
"ember/index.d.ts"
],
"preview": [
"dist/preview.d.ts"
]
}
},
"files": [
"dist/**/*",
"angular/**/*",
Expand All @@ -106,7 +87,7 @@
"!src/**/*"
],
"scripts": {
"check": "jiti ../../../scripts/prepare/check.ts",
"check": "jiti ../../../scripts/check/check-package.ts",
"prep": "jiti ../../../scripts/prepare/addon-bundle.ts"
},
"dependencies": {
Expand Down Expand Up @@ -162,7 +143,7 @@
"./src/manager.tsx"
]
},
"gitHead": "e6a7fd8a655c69780bc20b9749c2699e44beae16",
"gitHead": "e6e7fd8a655c69780bc20b9749c2699e44beae16",
"storybook": {
"displayName": "Docs",
"icon": "https://user-images.githubusercontent.com/263385/101991672-48355c80-3c7c-11eb-82d9-95fa12438f64.png",
Expand Down
4 changes: 2 additions & 2 deletions code/addons/jest/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@
"!src/**/*"
],
"scripts": {
"check": "jiti ../../../scripts/prepare/check.ts",
"check": "jiti ../../../scripts/check/check-package.ts",
"prep": "jiti ../../../scripts/prepare/addon-bundle.ts"
},
"dependencies": {
Expand Down Expand Up @@ -76,7 +76,7 @@
"./src/manager.tsx"
]
},
"gitHead": "e6a7fd8a655c69780bc20b9749c2699e44beae16",
"gitHead": "e6e7fd8a655c69780bc20b9749c2699e44beae16",
"storybook": {
"displayName": "Jest",
"icon": "https://pbs.twimg.com/profile_images/821713465245102080/mMtKIMax_400x400.jpg",
Expand Down
17 changes: 2 additions & 15 deletions code/addons/links/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -43,19 +43,6 @@
"main": "dist/index.js",
"module": "dist/index.mjs",
"types": "dist/index.d.ts",
"typesVersions": {
"*": {
"*": [
"dist/index.d.ts"
],
"preview": [
"dist/preview.d.ts"
],
"react": [
"dist/react/index.d.ts"
]
}
},
"files": [
"dist/**/*",
"README.md",
Expand All @@ -64,7 +51,7 @@
"!src/**/*"
],
"scripts": {
"check": "jiti ../../../scripts/prepare/check.ts",
"check": "jiti ../../../scripts/check/check-package.ts",
"prep": "jiti ../../../scripts/prepare/addon-bundle.ts"
},
"dependencies": {
Expand Down Expand Up @@ -98,7 +85,7 @@
],
"post": "./scripts/fix-preview-api-reference.ts"
},
"gitHead": "e6a7fd8a655c69780bc20b9749c2699e44beae16",
"gitHead": "e6e7fd8a655c69780bc20b9749c2699e44beae16",
"storybook": {
"displayName": "Links",
"icon": "https://user-images.githubusercontent.com/263385/101991673-48355c80-3c7c-11eb-9b6e-b627c96a75f6.png",
Expand Down
2 changes: 1 addition & 1 deletion code/addons/onboarding/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
"!src/**/*"
],
"scripts": {
"check": "jiti ../../../scripts/prepare/check.ts",
"check": "jiti ../../../scripts/check/check-package.ts",
"prep": "jiti ../../../scripts/prepare/addon-bundle.ts"
},
"devDependencies": {
Expand Down
Loading
Loading