docs(misc): improve grammar and fix typos
This commit is contained in:
parent
e40c65194d
commit
af27f975a4
@ -28,7 +28,7 @@ nx build myapp --prod
|
||||
|
||||
## Options
|
||||
|
||||
The options below are common to the `build` command used within an Nx workspace. The Web and Angular-specifc build options are listed after these options.
|
||||
The options below are common to the `build` command used within an Nx workspace. The Web and Angular-specific build options are listed after these options.
|
||||
|
||||
### baseHref
|
||||
|
||||
|
||||
@ -40,7 +40,7 @@ nx e2e myapp-e2e --watch
|
||||
|
||||
## Common Options
|
||||
|
||||
The options below are common to the E2E commands used within an Nx workspace. Cypress and Protractor-specifc options are listed below.
|
||||
The options below are common to the E2E commands used within an Nx workspace. Cypress and Protractor-specific options are listed below.
|
||||
|
||||
### baseUrl
|
||||
|
||||
|
||||
@ -28,7 +28,7 @@ nx lint myapp --fix
|
||||
|
||||
## Common Options
|
||||
|
||||
The options below are common to the `lint` command used within an Nx workspace. The ESLint and Angular-specifc lint options are listed after these options.
|
||||
The options below are common to the `lint` command used within an Nx workspace. The ESLint and Angular-specific lint options are listed after these options.
|
||||
|
||||
### exclude
|
||||
|
||||
|
||||
@ -28,7 +28,7 @@ nx serve myapp
|
||||
|
||||
## Common Options
|
||||
|
||||
The options below are common to the `serve` command used within an Nx workspace. The Web and Angular-specifc serve options are listed after these options.
|
||||
The options below are common to the `serve` command used within an Nx workspace. The Web and Angular-specific serve options are listed after these options.
|
||||
|
||||
### allowedHosts
|
||||
|
||||
|
||||
@ -28,7 +28,7 @@ nx test myapp
|
||||
|
||||
## Common Options
|
||||
|
||||
The options below are common to the `test` command used within an Nx workspace. The Jest and Karma-specifc test options are listed after these options.
|
||||
The options below are common to the `test` command used within an Nx workspace. The Jest and Karma-specific test options are listed after these options.
|
||||
|
||||
### codeCoverage
|
||||
|
||||
@ -241,7 +241,7 @@ Karma reporters to use. Directly passed to the karma runner.
|
||||
|
||||
Output sourcemaps.
|
||||
|
||||
### tsCconfig
|
||||
### tsConfig
|
||||
|
||||
The name of the TypeScript configuration file.
|
||||
|
||||
|
||||
@ -205,7 +205,7 @@ In that case, when you run the Nx migration scripts, the scripts will ignore the
|
||||
|
||||
The `@nrwl/angular:storybook-migrate-defaults-5-to-6` generator will not exactly do a migration. It will perform the following actions:
|
||||
|
||||
- It will generate new Storybook configuration files using the new (`>6.x`) Storybook way. The way it will do that is, it will look into `workspace.json` and it will find all the projects that have a `Storybook` configuration. Using the `configFolder` path provided there, it will go and generate new Storybook instaces in all these paths. Finally, it will generate a new Storybook instance at the root directory.
|
||||
- It will generate new Storybook configuration files using the new (`>6.x`) Storybook way. The way it will do that is, it will look into `workspace.json` and it will find all the projects that have a `Storybook` configuration. Using the `configFolder` path provided there, it will go and generate new Storybook instances in all these paths. Finally, it will generate a new Storybook instance at the root directory.
|
||||
|
||||
- If you choose to `keepOld`, then it will add all your existing Storybook configuration files into another folder labeled `.old_storybook`.
|
||||
|
||||
@ -267,7 +267,7 @@ Please check out this official [Storybook 6 Migration Guide](https://medium.com/
|
||||
|
||||
#### Step 3: Upgrade all `@storybook/*` packages in your project
|
||||
|
||||
Check your `package.json` file for all `@storybook` packages. Install the latest versions of these, usign `yarn`:
|
||||
Check your `package.json` file for all `@storybook` packages. Install the latest versions of these, using `yarn`:
|
||||
|
||||
For example:
|
||||
|
||||
|
||||
@ -28,7 +28,7 @@ nx build myapp --prod
|
||||
|
||||
## Options
|
||||
|
||||
The options below are common to the `build` command used within an Nx workspace. The Web and Angular-specifc build options are listed after these options.
|
||||
The options below are common to the `build` command used within an Nx workspace. The Web and Angular-specific build options are listed after these options.
|
||||
|
||||
### baseHref
|
||||
|
||||
|
||||
@ -40,7 +40,7 @@ nx e2e myapp-e2e --watch
|
||||
|
||||
## Common Options
|
||||
|
||||
The options below are common to the E2E commands used within an Nx workspace. Cypress and Protractor-specifc options are listed below.
|
||||
The options below are common to the E2E commands used within an Nx workspace. Cypress and Protractor-specific options are listed below.
|
||||
|
||||
### baseUrl
|
||||
|
||||
|
||||
@ -28,7 +28,7 @@ nx lint myapp --fix
|
||||
|
||||
## Common Options
|
||||
|
||||
The options below are common to the `lint` command used within an Nx workspace. The ESLint and Angular-specifc lint options are listed after these options.
|
||||
The options below are common to the `lint` command used within an Nx workspace. The ESLint and Angular-specific lint options are listed after these options.
|
||||
|
||||
### exclude
|
||||
|
||||
|
||||
@ -28,7 +28,7 @@ nx serve myapp
|
||||
|
||||
## Common Options
|
||||
|
||||
The options below are common to the `serve` command used within an Nx workspace. The Web and Angular-specifc serve options are listed after these options.
|
||||
The options below are common to the `serve` command used within an Nx workspace. The Web and Angular-specific serve options are listed after these options.
|
||||
|
||||
### allowedHosts
|
||||
|
||||
|
||||
@ -28,7 +28,7 @@ nx test myapp
|
||||
|
||||
## Common Options
|
||||
|
||||
The options below are common to the `test` command used within an Nx workspace. The Jest and Karma-specifc test options are listed after these options.
|
||||
The options below are common to the `test` command used within an Nx workspace. The Jest and Karma-specific test options are listed after these options.
|
||||
|
||||
### codeCoverage
|
||||
|
||||
@ -241,7 +241,7 @@ Karma reporters to use. Directly passed to the karma runner.
|
||||
|
||||
Output sourcemaps.
|
||||
|
||||
### tsCconfig
|
||||
### tsConfig
|
||||
|
||||
The name of the TypeScript configuration file.
|
||||
|
||||
|
||||
@ -49,7 +49,7 @@ export type Todo = {
|
||||
|
||||
If you're using [VS Code](https://code.visualstudio.com/) it may be necessary at this point to restart the TS server so that the new `@myorg/data` package is recognised. This needs to be done **every time a new workspace library is added**.
|
||||
|
||||
Use the command pallette with a `*.ts` file open and choose `Restart TS Server`.
|
||||
Use the command palette with a `*.ts` file open and choose `Restart TS Server`.
|
||||
|
||||
## Refactor the Todos Service
|
||||
|
||||
|
||||
@ -28,7 +28,7 @@ nx build myapp --prod
|
||||
|
||||
## Options
|
||||
|
||||
The options below are common to the `build` command used within an Nx workspace. The Web and Angular-specifc build options are listed after these options.
|
||||
The options below are common to the `build` command used within an Nx workspace. The Web and Angular-specific build options are listed after these options.
|
||||
|
||||
### baseHref
|
||||
|
||||
|
||||
@ -40,7 +40,7 @@ nx e2e myapp-e2e --watch
|
||||
|
||||
## Common Options
|
||||
|
||||
The options below are common to the E2E commands used within an Nx workspace. Cypress and Protractor-specifc options are listed below.
|
||||
The options below are common to the E2E commands used within an Nx workspace. Cypress and Protractor-specific options are listed below.
|
||||
|
||||
### baseUrl
|
||||
|
||||
|
||||
@ -28,7 +28,7 @@ nx lint myapp --fix
|
||||
|
||||
## Common Options
|
||||
|
||||
The options below are common to the `lint` command used within an Nx workspace. The ESLint and Angular-specifc lint options are listed after these options.
|
||||
The options below are common to the `lint` command used within an Nx workspace. The ESLint and Angular-specific lint options are listed after these options.
|
||||
|
||||
### exclude
|
||||
|
||||
|
||||
@ -28,7 +28,7 @@ nx serve myapp
|
||||
|
||||
## Common Options
|
||||
|
||||
The options below are common to the `serve` command used within an Nx workspace. The Web and Angular-specifc serve options are listed after these options.
|
||||
The options below are common to the `serve` command used within an Nx workspace. The Web and Angular-specific serve options are listed after these options.
|
||||
|
||||
### allowedHosts
|
||||
|
||||
|
||||
@ -28,7 +28,7 @@ nx test myapp
|
||||
|
||||
## Common Options
|
||||
|
||||
The options below are common to the `test` command used within an Nx workspace. The Jest and Karma-specifc test options are listed after these options.
|
||||
The options below are common to the `test` command used within an Nx workspace. The Jest and Karma-specific test options are listed after these options.
|
||||
|
||||
### codeCoverage
|
||||
|
||||
@ -241,7 +241,7 @@ Karma reporters to use. Directly passed to the karma runner.
|
||||
|
||||
Output sourcemaps.
|
||||
|
||||
### tsCconfig
|
||||
### tsConfig
|
||||
|
||||
The name of the TypeScript configuration file.
|
||||
|
||||
|
||||
@ -187,7 +187,7 @@ In that case, when you run the Nx migration scripts, the scripts will ignore the
|
||||
|
||||
The `@nrwl/react:storybook-migrate-defaults-5-to-6` generator will not exactly do a migration. It will perform the following actions:
|
||||
|
||||
- It will generate new Storybook configuration files using the new (`>6.x`) Storybook way. The way it will do that is, it will look into `workspace.json` and it will find all the projects that have a `Storybook` configuration. Using the `configFolder` path provided there, it will go and generate new Storybook instaces in all these paths. Finally, it will generate a new Storybook instance at the root directory.
|
||||
- It will generate new Storybook configuration files using the new (`>6.x`) Storybook way. The way it will do that is, it will look into `workspace.json` and it will find all the projects that have a `Storybook` configuration. Using the `configFolder` path provided there, it will go and generate new Storybook instances in all these paths. Finally, it will generate a new Storybook instance at the root directory.
|
||||
|
||||
- If you choose to `keepOld`, then it will add all your existing Storybook configuration files into another folder labeled `.old_storybook`.
|
||||
|
||||
@ -247,7 +247,7 @@ Please check out this official [Storybook 6 Migration Guide](https://medium.com/
|
||||
|
||||
#### Step 3: Upgrade all `@storybook/*` packages in your project
|
||||
|
||||
Check your `package.json` file for all `@storybook` packages. Install the latest versions of these, usign `yarn`:
|
||||
Check your `package.json` file for all `@storybook` packages. Install the latest versions of these, using `yarn`:
|
||||
|
||||
For example:
|
||||
|
||||
|
||||
@ -28,7 +28,7 @@ nx build myapp --prod
|
||||
|
||||
## Options
|
||||
|
||||
The options below are common to the `build` command used within an Nx workspace. The Web and Angular-specifc build options are listed after these options.
|
||||
The options below are common to the `build` command used within an Nx workspace. The Web and Angular-specific build options are listed after these options.
|
||||
|
||||
### baseHref
|
||||
|
||||
|
||||
@ -40,7 +40,7 @@ nx e2e myapp-e2e --watch
|
||||
|
||||
## Common Options
|
||||
|
||||
The options below are common to the E2E commands used within an Nx workspace. Cypress and Protractor-specifc options are listed below.
|
||||
The options below are common to the E2E commands used within an Nx workspace. Cypress and Protractor-specific options are listed below.
|
||||
|
||||
### baseUrl
|
||||
|
||||
|
||||
@ -28,7 +28,7 @@ nx lint myapp --fix
|
||||
|
||||
## Common Options
|
||||
|
||||
The options below are common to the `lint` command used within an Nx workspace. The ESLint and Angular-specifc lint options are listed after these options.
|
||||
The options below are common to the `lint` command used within an Nx workspace. The ESLint and Angular-specific lint options are listed after these options.
|
||||
|
||||
### exclude
|
||||
|
||||
|
||||
@ -28,7 +28,7 @@ nx serve myapp
|
||||
|
||||
## Common Options
|
||||
|
||||
The options below are common to the `serve` command used within an Nx workspace. The Web and Angular-specifc serve options are listed after these options.
|
||||
The options below are common to the `serve` command used within an Nx workspace. The Web and Angular-specific serve options are listed after these options.
|
||||
|
||||
### allowedHosts
|
||||
|
||||
|
||||
@ -28,7 +28,7 @@ nx test myapp
|
||||
|
||||
## Common Options
|
||||
|
||||
The options below are common to the `test` command used within an Nx workspace. The Jest and Karma-specifc test options are listed after these options.
|
||||
The options below are common to the `test` command used within an Nx workspace. The Jest and Karma-specific test options are listed after these options.
|
||||
|
||||
### codeCoverage
|
||||
|
||||
@ -241,7 +241,7 @@ Karma reporters to use. Directly passed to the karma runner.
|
||||
|
||||
Output sourcemaps.
|
||||
|
||||
### tsCconfig
|
||||
### tsConfig
|
||||
|
||||
The name of the TypeScript configuration file.
|
||||
|
||||
|
||||
@ -51,7 +51,7 @@ You can also launch the `Generate` action from the Command Palette (`⇧⌘P`) b
|
||||
|
||||
<iframe width="560" height="420" src="https://www.youtube.com/embed/Sk2XjFwF8Zo?rel=0" frameborder="0" allow="accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe>
|
||||
|
||||
You can even construct the generator options while staying entirely within the Command Palette. Use `⇧⌘P` to open the Command Palette, then select `nx: generate`. After choosing a generator, select any of the listed options to modify the generator command. When you're satified with the constructed command, choose the `Execute` command at the top of the list.
|
||||
You can even construct the generator options while staying entirely within the Command Palette. Use `⇧⌘P` to open the Command Palette, then select `nx: generate`. After choosing a generator, select any of the listed options to modify the generator command. When you're satisfied with the constructed command, choose the `Execute` command at the top of the list.
|
||||
|
||||
<iframe width="560" height="420" src="https://www.youtube.com/embed/q5NTTqRYq9c?rel=0" frameborder="0" allow="accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe>
|
||||
|
||||
@ -63,7 +63,7 @@ The `Run` action allows you to choose a builder command and then opens a form li
|
||||
|
||||
**From the Command Pallete**
|
||||
|
||||
You can also construct the builder command options while staying entirely within the Command Palette. Use `⇧⌘P` to open the Command Palette, then select `nx: test`. After choosing a project, select any of the listed options to modify the builder command options. When you're satified with the constructed command, choose the `Execute` command at the top of the list.
|
||||
You can also construct the builder command options while staying entirely within the Command Palette. Use `⇧⌘P` to open the Command Palette, then select `nx: test`. After choosing a project, select any of the listed options to modify the builder command options. When you're satisfied with the constructed command, choose the `Execute` command at the top of the list.
|
||||
|
||||
<iframe width="560" height="420" src="https://www.youtube.com/embed/CsUkSyQcxwQ?rel=0" frameborder="0" allow="accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe>
|
||||
|
||||
|
||||
@ -49,7 +49,7 @@ The above chart has three different test runs:
|
||||
|
||||
## When should I use incremental builds
|
||||
|
||||
We're continously improving the speed of incremental builds. However as of now, incremental builds become really benefitial in **really large repositories**.
|
||||
We're continuously improving the speed of incremental builds. However as of now, incremental builds become really beneficial in **really large repositories**.
|
||||
|
||||
Also, using incremental builds only really makes sense when using the distributed Nx caching with Nx Cloud. Check out [nx.app](https://nx.app) for more information on how to setup distributed caching.
|
||||
|
||||
|
||||
@ -16,7 +16,7 @@ But they come with their own technical challenges. The more code you add into yo
|
||||
|
||||
[This repo](https://github.com/nrwl/nx-azure-build) is an example Nx Workspace. It has two applications. Each app has 15 libraries, each of which consists of 30 components. The two applications also share code.
|
||||
|
||||
If you run `nx dep-graph`, you will see somethign like this:
|
||||
If you run `nx dep-graph`, you will see something like this:
|
||||
|
||||

|
||||
|
||||
@ -91,7 +91,7 @@ jobs:
|
||||
- script: yarn nx affected --target=build --base=origin/master --prod --parallel
|
||||
```
|
||||
|
||||
This helps but it still has a ceiling. At some point, this won't be enough. A single agent is simply insufficent. You need to distribute CI across a grid of machines.
|
||||
This helps but it still has a ceiling. At some point, this won't be enough. A single agent is simply insufficient. You need to distribute CI across a grid of machines.
|
||||
|
||||
## Distributed CI
|
||||
|
||||
@ -277,7 +277,7 @@ This example uses a fixed agent graph. This setup works without any problems for
|
||||
|
||||
## Summary
|
||||
|
||||
1. Rebuilding/retesting/relinting everyting on every code change doesn't scale. **In this example it takes 45 minutes.**
|
||||
1. Rebuilding/retesting/relinting everything on every code change doesn't scale. **In this example it takes 45 minutes.**
|
||||
2. Nx lets you rebuild only what is affected, which drastically improves the average CI time, but it doesn't address the worst-case scenario.
|
||||
3. Nx helps you run multiple targets in parallel on the same machine.
|
||||
4. Nx provides `print-affected` and `run-many` which make implemented distributed CI simple. **In this example the time went down from 45 minutes to only 7**
|
||||
|
||||
@ -10,13 +10,13 @@ Nx is a set of extensible dev tools for monorepos. Monorepos provide a lot of ad
|
||||
- Consistent developer experience
|
||||
- ...
|
||||
|
||||
But they come with their own technical challenges. The more code you add into your repository, the slower the CI gets.
|
||||
However, they come with their own technical challenges. The more code you add into your repository, the slower the CI gets.
|
||||
|
||||
## Example Workspace
|
||||
|
||||
[This repo](https://github.com/nrwl/nx-jenkins-build) is an example Nx Workspace. It has two applications. Each app has 15 libraries, each of which consists of 30 components. The two applications also share code.
|
||||
|
||||
If you run `nx dep-graph`, you will see somethign like this:
|
||||
If you run `nx dep-graph`, you will see something like this:
|
||||
|
||||

|
||||
|
||||
@ -123,7 +123,7 @@ node {
|
||||
}
|
||||
```
|
||||
|
||||
This helps but it still has a ceiling. At some point, this won't be enough. A single agent is simply insufficent. You need to distribute CI across a grid of machines.
|
||||
This helps, but it still has a ceiling. At some point, this won't be enough. A single agent is simply insufficient. You need to distribute CI across a grid of machines.
|
||||
|
||||
## Distributed CI
|
||||
|
||||
@ -281,7 +281,7 @@ With these changes, rebuild/retesting/relinting everything takes only 7 minutes.
|
||||
|
||||
## Summary
|
||||
|
||||
1. Rebuilding/retesting/relinting everyting on every code change doesn't scale. **In this example it takes 45 minutes.**
|
||||
1. Rebuilding/retesting/relinting everything on every code change doesn't scale. **In this example it takes 45 minutes.**
|
||||
2. Nx lets you rebuild only what is affected, which drastically improves the average CI time, but it doesn't address the worst-case scenario.
|
||||
3. Nx helps you run multiple targets in parallel on the same machine.
|
||||
4. Nx provides `print-affected` and `run-many` which make implemented distributed CI simple. **In this example the time went down from 45 minutes to only 7**
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
# Using Nx at Enterprises
|
||||
|
||||
Nx is a great tool for companies of all sizes. These days even small products have several microservies and several frontends (say desktop and mobile) which are often built by distributed teams. Being able to do this type of development holistically, using modern tools, is as important for a startup as it is for a well-established organization.
|
||||
Nx is a great tool for companies of all sizes. These days even small products have several microservices and several frontends (say desktop and mobile) which are often built by distributed teams. Being able to do this type of development holistically, using modern tools, is as important for a startup as it is for a well-established organization.
|
||||
|
||||
Some things, however, are much more important for large companies:
|
||||
|
||||
|
||||
@ -140,7 +140,7 @@ The `builder.json` file provides the description of your builder to the CLI.
|
||||
}
|
||||
```
|
||||
|
||||
Note that this `builder.json` file is naming our builder 'echo' for the CLI's purposes, and maping that name to the given implemetation file and schema.
|
||||
Note that this `builder.json` file is naming our builder 'echo' for the CLI's purposes, and mapping that name to the given implementation file and schema.
|
||||
|
||||
### package.json
|
||||
|
||||
|
||||
@ -297,7 +297,7 @@ Running the generator without providing a value for the type will prompt the use
|
||||
|
||||
### With Visual Studio Code
|
||||
|
||||
1. Open the Command Pallette and choose `Debug: Create JavaScript Debug Terminal`.
|
||||
1. Open the Command Palette and choose `Debug: Create JavaScript Debug Terminal`.
|
||||
This will open a terminal with debugging enabled.
|
||||
2. Set breakpoints in your code
|
||||
3. Run `nx workspace-generator my-generator` in the debug terminal.
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user