diff --git a/docs/shared/plugin-features/use-code-generators.md b/docs/shared/plugin-features/use-code-generators.md index 4c088b275eb8c..9aab1ebd259c0 100644 --- a/docs/shared/plugin-features/use-code-generators.md +++ b/docs/shared/plugin-features/use-code-generators.md @@ -21,6 +21,16 @@ nx generate @nx/react:component mycmp --project=myapp It is important to have a clean git working directory before invoking a generator so that you can easily revert changes and re-invoke the generator with different inputs. +## Build your own Generator + +Nx comes with a Devkit that allows you to build your own generator for your Nx workspace. Learn more about it on [our docs page](/extending-nx/recipes/local-generators) or have a look at the video below: + +{% youtube +src="https://www.youtube.com/embed/myqfGDWC2go" +title="Scaffold new Pkgs in a PNPM Workspaces Monorepo" +caption="Demoes how to use Nx generators in a PNPM workspace to automate the creation of libraries" +/%} + ## See Also - [nx.json generator defaults](/reference/nx-json#generators) diff --git a/docs/shared/plugin-features/use-task-executors.md b/docs/shared/plugin-features/use-task-executors.md index 6e4f42612c50b..dcfe339a7d434 100644 --- a/docs/shared/plugin-features/use-task-executors.md +++ b/docs/shared/plugin-features/use-task-executors.md @@ -170,3 +170,7 @@ For example, running e2e tests for multiple environments. By default it would ma When running `nx e2e my-app-e2e`, the _dev_ configuration will be used. In this case using the local dev server for `my-app`. You can always run the other configurations by explicitly providing the configuration i.e. `nx e2e my-app-e2e --configuration=qa` or `nx run my-app-e2e:e2e:qa` + +## Build your own Executor + +Nx comes with a Devkit that allows you to build your own executor to automate your Nx workspace. Learn more about it in the [docs page about creating a local executor](/extending-nx/recipes/local-executors). diff --git a/docs/shared/recipes/generators/local-generators.md b/docs/shared/recipes/generators/local-generators.md index 1d471b3509b2a..71af382977e76 100644 --- a/docs/shared/recipes/generators/local-generators.md +++ b/docs/shared/recipes/generators/local-generators.md @@ -15,11 +15,12 @@ caption="Demoes how to use Nx generators in a PNPM workspace to automate the cre If you don't already have a local plugin, use Nx to generate one: ```shell -# replace `latest` with the version that matches your Nx version npm install @nx/plugin@latest nx g @nx/plugin:plugin my-plugin ``` +Note that `latest` should match the version of the `nx` plugins installed in your workspace. + Use the Nx CLI to generate the initial files needed for your generator. ```shell