nx/docs/shared/recipes/set-up-a-new-workspace.md
Isaac Mann e717660102
docs(nx-dev): diataxis restructure (#11649)
* docs(nxdev): restructure docs to diataxis style

* docs(nxdev): cleanup

* docs(nxdev): fix links

* chore(nxdev): format

* docs(nxdev): fix broken images

* docs(nxdev): fix links

* docs(nxdev): fix links

* docs(nxdev): fix links

* docs(nxdev): tweaks

* docs(nxdev): redirect rules

* docs(nxdev): fixes
2022-08-29 08:36:55 -04:00

944 B

Set up a New Nx Workspace

Run the following command to create a new workspace.

# pass @latest in case npx cached an older version of create-nx-workspace
npx create-nx-workspace@latest

When creating a workspace, you will have to choose a preset, which will preconfigure a few things for you.

# create an empty workspace set up for building applications
npx create-nx-workspace --preset=apps

# create an empty workspace set up for building packages
npx create-nx-workspace --preset=core

# create an empty workspace set up for building packages with the @nrwl/js plugin installed
npx create-nx-workspace --preset=ts

Some presets set up applications, e2e tests, etc.

npx create-nx-workspace --preset=react
npx create-nx-workspace --preset=react-native
npx create-nx-workspace --preset=angular

For more information about possible options see the create-nx-workspace command.