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

fix(core): Remove nameAndDirectoryFormat option from generators #28110

Open
wants to merge 8 commits into
base: master
Choose a base branch
from

Conversation

ndcunningham
Copy link
Contributor

Current Behavior

Currently, when we use generator's via the CLI passing the name arg has more than one responsibility:

  1. it can be used as a path
  2. it can be used as the generator's name (e.g. Component name)

This is not intuitive as if we use via Nx Console because it creates some ambiguity around the --name property which is normally described as only 2.
image

Expected Behavior

What is expected is that the name property should only have the responsibility of determining the name of the generated module (Component, Directive etc...).

The new property path replaces the directory property but fulfils the same purpose as determining where the module should be created.

Related Issue(s)

Fixes #

@ndcunningham ndcunningham self-assigned this Sep 25, 2024
Copy link

vercel bot commented Sep 25, 2024

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

Name Status Preview Updated (UTC)
nx-dev ✅ Ready (Inspect) Visit Preview Sep 30, 2024 5:36pm

@ndcunningham ndcunningham marked this pull request as ready for review September 26, 2024 23:00
@ndcunningham ndcunningham force-pushed the fix/refactor-name-and-directory-format branch 3 times, most recently from fe65e46 to 088086c Compare September 27, 2024 19:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants