You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is your feature request related to a problem? Please describe.
tldr; I'd like to be able to customise the conditions property in the builder-manager esbuild config.
I'm looking to use export custom conditions in a monorepo to resolve from source during dev/builds without the need to build all the packages first or impact how the public npm packages are consumed outside the repo. e.g.
Like this I can update tooling to use the @app/src custom condition and we don't need to build all packages up front during dev / lint / etc.
However I cannot find a way to push the @app/src condition into the manager esbuild config which I need to do as the projects storybook manager.ts imports from pkgA.
Describe the solution you'd like
I'm not really sure how best to solve this as the manager builder package and it's API aren't intended for public consumption. There's a couple of env vars already in use in the esbuild config for browser targets and supported features. Maybe we could add an env var for this?
Describe alternatives you've considered
I'm currently using yarn patch to add the custom condition to storybook-core on install. It works but it's far from ideal considering updating dependencies.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Is your feature request related to a problem? Please describe.
tldr; I'd like to be able to customise the conditions property in the builder-manager esbuild config.
I'm looking to use export custom conditions in a monorepo to resolve from source during dev/builds without the need to build all the packages first or impact how the public npm packages are consumed outside the repo. e.g.
Like this I can update tooling to use the
@app/srccustom condition and we don't need to build all packages up front during dev / lint / etc.However I cannot find a way to push the
@app/srccondition into the manager esbuild config which I need to do as the projects storybookmanager.tsimports frompkgA.Describe the solution you'd like
I'm not really sure how best to solve this as the manager builder package and it's API aren't intended for public consumption. There's a couple of env vars already in use in the esbuild config for browser targets and supported features. Maybe we could add an env var for this?
Describe alternatives you've considered
I'm currently using
yarn patchto add the custom condition to storybook-core on install. It works but it's far from ideal considering updating dependencies.Are you able to assist to bring the feature to reality?
yes, I can
Additional context
No response
Beta Was this translation helpful? Give feedback.
All reactions