Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

fix: angular framework options#33190

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Open
arty-name wants to merge1 commit intostorybookjs:next
base:next
Choose a base branch
Loading
fromarty-name:fix/angular-framework-options

Conversation

@arty-name
Copy link
Contributor

Closes#31908

What I did

Added code to propagate theangularBuilderOptions frommain.ts#framework.options to the options

Checklist for Contributors

Testing

The changes in this PR are covered in the following automated tests:

  • stories
  • unit tests
  • integration tests
  • end-to-end tests

Manual testing

This section is mandatory for all contributions. If you believe no manual test is necessary, please state so explicitly. Thanks!

  1. Configure main.ts to include e.g.
  framework: {    name: '@storybook/angular',    options: {      angularBuilderOptions: {        styles: ['src/styles.css'],      },    },  },
  1. Verify thatstyles is present inoptions.angularBuilderOptions

Documentation

  • Add or update documentation reflecting your changes
  • If you are deprecating/removing a feature, make sure to update
    MIGRATION.MD

Checklist for Maintainers

  • When this PR is ready for testing, make sure to addci:normal,ci:merged orci:daily GH label to it to run a specific set of sandboxes. The particular set of sandboxes can be found incode/lib/cli-storybook/src/sandbox-templates.ts

  • Make sure this PR containsone of the labels below:

    Available labels
    • bug: Internal changes that fixes incorrect behavior.
    • maintenance: User-facing maintenance tasks.
    • dependencies: Upgrading (sometimes downgrading) dependencies.
    • build: Internal-facing build tooling & test updates. Will not show up in release changelog.
    • cleanup: Minor cleanup style change. Will not show up in release changelog.
    • documentation: Documentationonly changes. Will not show up in release changelog.
    • feature request: Introducing a new feature.
    • BREAKING CHANGE: Changes that break compatibility in some way with current major version.
    • other: Changes that don't fit in the above categories.

🦋 Canary release

This PR does not have a canary release associated. You can request a canary release of this pull request by mentioning the@storybookjs/core team here.

core team members can create a canary releasehere or locally withgh workflow run --repo storybookjs/storybook publish.yml --field pr=<PR_NUMBER>

@arty-name
Copy link
ContributorAuthor

While#31908 mentions two workarounds, one of them requires modification of the storybook file, and another needs storybook to be run through ng+angular.json. I run storybook asstorybook dev and I can’t activate zoneless Angular via themain.ts#framework.options

@valentinpalkovic
Copy link
Contributor

valentinpalkovic commentedNov 26, 2025
edited
Loading

Hi@arty-name

Thank you for your contribution.

angularBuilderOptions is not an option in the Storybook framework. Instead, the builder options have to be defined in your nx/angular.json's builder configuration forstorybook andbuild-storybook. For more info:https://storybook.js.org/docs/get-started/frameworks/angular

@arty-name
Copy link
ContributorAuthor

Thank you for the prompt response,@valentinpalkovic!

I’ve finished writing my explanation of why ng+angular.json is not a good fit for my case right before your comment came in.

This PR doesn’t modify the core of storybook, only the Angular plugin, which already deals with angularBuilderOptions quite some. I’m just extending this a little more.

@nx-cloud
Copy link

nx-cloudbot commentedNov 26, 2025
edited
Loading

View yourCI Pipeline Execution ↗ for commitf0c0e14

CommandStatusDurationResult
nx run-many -t build --parallel=3✅ Succeeded43sView ↗

☁️Nx Cloud last updated this comment at2025-11-26 14:43:17 UTC

@valentinpalkovic
Copy link
Contributor

valentinpalkovic commentedNov 26, 2025
edited
Loading

Can you elaborate of why you're runningstorybook dev. This is discouraged when using@storybook/angular. I can imagine that you're poking around with Analog.js' Vite-based Storybook framework?

@arty-name
Copy link
ContributorAuthor

That’s the right guess! Our Angular projects use Vite for building, and Analog’s@analogjs/vite-plugin-angular and@analogjs/storybook-angular come in handy.

Using the standardstorybook dev with them worked as a possible and more lightweight option.

Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

No reviews

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

[Bug]: framework.options.angularBuilderOptions in .storybook/main.ts is ignored and does not reach getBuilderOptions() in Angular integration

2 participants

@arty-name@valentinpalkovic

[8]ページ先頭

©2009-2025 Movatter.jp