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

Add Angular Builder Codemods #21409

Merged
merged 1 commit into from
Mar 6, 2023
Merged

Conversation

valentinpalkovic
Copy link
Contributor

@valentinpalkovic valentinpalkovic commented Mar 6, 2023

Closes #20947

What I did

Added two auto migrations for Angular. The first one will output a prompt to notify the user that the migration must be done manually in multi-project Angular workspaces. The other one will automatically configure the angular.json properly to use the Storybook Angular builder instead of directly calling storybook dev or storybook build.

How to test

  1. Select an Angular project with Angular v. 14 or higher.
  2. Select a project with several Angular projects specified without having a root project defined in the angular.json -> Run the upgrade command. No auto-migration is triggered. Instead, the user will see a notification to upgrade manually.
  3. Select a project with one Angular project or one root Angular project -> Run the upgrade command. The auto-migration should add some entries to the angular.json to set up Storybook properly. Additionally, the commands in the scripts section of the package.json are adjusted as well.

Checklist

  • Make sure your changes are tested (stories and/or unit, integration, or end-to-end tests)
  • Make sure to add/update documentation regarding your changes
  • If you are deprecating/removing a feature, make sure to update
    MIGRATION.MD

Maintainers

  • If this PR should be tested against many or all sandboxes,
    make sure to add the ci:merged or ci:daily GH label to it.
  • Make sure this PR contains one of the labels below.

["cleanup", "BREAKING CHANGE", "feature request", "bug", "documentation", "maintenance", "dependencies", "other"]

@valentinpalkovic valentinpalkovic merged commit 541c0d7 into next Mar 6, 2023
@valentinpalkovic valentinpalkovic deleted the valentin/angular-codemod branch March 6, 2023 12:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Automigration for undefined angularBrowserEventTarget
2 participants