Skip to content

refactor(step-by-step): change the default framework to Angular instead#1574

Merged
damyanpetev merged 3 commits intomasterfrom
dpetev/step-default-framework
Mar 30, 2026
Merged

refactor(step-by-step): change the default framework to Angular instead#1574
damyanpetev merged 3 commits intomasterfrom
dpetev/step-default-framework

Conversation

@damyanpetev
Copy link
Copy Markdown
Member

Closes # .

Additional information related to this pull request:

@coveralls
Copy link
Copy Markdown

coveralls commented Mar 27, 2026

Coverage Status

coverage: 84.816%. remained the same
when pulling 0d5034d on dpetev/step-default-framework
into ca4c52f on master.

@damyanpetev damyanpetev marked this pull request as ready for review March 30, 2026 06:26
Copilot AI review requested due to automatic review settings March 30, 2026 06:26
@damyanpetev damyanpetev requested a review from kdinev March 30, 2026 06:26
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Updates the step-by-step project creation wizard to default to Angular when prompting the user to choose a framework.

Changes:

  • Changed the framework prompt default from jQuery to Angular in the core prompt session.
  • Changed the framework prompt default from jQuery to Angular in the CLI prompt session.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.

File Description
packages/core/prompt/BasePromptSession.ts Updates the default framework selection in the base step-by-step wizard prompt.
packages/cli/lib/PromptSession.ts Updates the default framework selection in the CLI’s step-by-step wizard prompt.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines 47 to 51
name: "framework",
message: "Choose framework:",
choices: this.getFrameworkNames(),
default: "jQuery"
default: "Angular"
});
Copy link

Copilot AI Mar 30, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The default is hard-coded to "Angular", but getFrameworkNames() can return a filtered list via config.stepByStep.frameworks that may not include Angular. This can leave the prompt with a default that isn't present in the choices (potentially causing an invalid preselection or a runtime error depending on the prompt implementation). Consider deriving the default from the computed choices (prefer Angular when present, otherwise fall back to the first choice).

Copilot uses AI. Check for mistakes.
Comment on lines 61 to 65
name: "framework",
message: "Choose framework:",
choices: this.getFrameworkNames(),
default: "jQuery"
default: "Angular"
});
Copy link

Copilot AI Mar 30, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same as in BasePromptSession: getFrameworkNames() may be filtered by config, so using a hard-coded default of "Angular" can result in a default that isn't in the choices list. Compute the default from the actual choices array (prefer Angular when present, else first choice) to keep the prompt valid under step-by-step filtering.

Copilot uses AI. Check for mistakes.
@damyanpetev damyanpetev merged commit 2f1bd38 into master Mar 30, 2026
3 checks passed
@damyanpetev damyanpetev deleted the dpetev/step-default-framework branch March 30, 2026 14:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants