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

feat(js): @nx/js:init generator does not generate prettier and tsconfig.base.json files by default #27406

Merged
merged 1 commit into from
Aug 14, 2024

Conversation

jaysoo
Copy link
Member

@jaysoo jaysoo commented Aug 13, 2024

In order to use nx release you must run nx add @nx/js. However, the init generator will add Prettier and tsconfig.base.json files by default, which is not what the user wants.

This PR adds two options:

  • addTsConfigBase - generates tsconfig.base.json when true. Default tofalse
  • setUpPrettier - adds prettier and generates .prettierrc and .prettierignore files when true. Defaults to false.

The programmatic initGenerator API defaults both options to true to usages remain unaffected.

The one behavior change is if users run nx g @nx/js:init then the two options default to false. However, since this is an internal API, the actual usages should be through nx add or the programmatic API.

Current Behavior

Expected Behavior

Related Issue(s)

Fixes #

@jaysoo jaysoo requested a review from a team as a code owner August 13, 2024 13:14
@jaysoo jaysoo requested a review from Coly010 August 13, 2024 13:14
Copy link

vercel bot commented Aug 13, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated (UTC)
nx-dev ✅ Ready (Inspect) Visit Preview Aug 14, 2024 0:21am

@jaysoo jaysoo merged commit d39624c into master Aug 14, 2024
6 checks passed
@jaysoo jaysoo deleted the feat/js-clean-init branch August 14, 2024 13:08
Copy link

This pull request has already been merged/closed. If you experience issues related to these changes, please open a new issue referencing this pull request.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Aug 28, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants