Skip to content

Commit

Permalink
feat(docs): update docs for TypeScript project refs
Browse files Browse the repository at this point in the history
  • Loading branch information
raymondfeng committed Apr 20, 2020
1 parent 8afd076 commit ef10c7f
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 2 deletions.
2 changes: 1 addition & 1 deletion docs/MAINTAINING.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ far!
- Commit (write) rights to `loopback-next` repo
- Ability to review and land pull requests, edit/categorize/close issues

## What are a maintainer's responsibilities?
## What are responsibilities of a maintainer?

We ask you to follow the existing processes, see
http://loopback.io/doc/en/contrib/Governance.html. This means mostly:
Expand Down
29 changes: 28 additions & 1 deletion docs/site/DEVELOPING.md
Original file line number Diff line number Diff line change
Expand Up @@ -71,12 +71,31 @@ for intra-dependencies:
npm ci
```

As part of `npm ci` or `npm i`, TypeScript project references are automatically
updated for each package with in the monorepo.

The next step is to compile all packages from TypeScript to JavaScript:

```sh
npm run build
```

To force a clean build:

```sh
npm run clean && npm run build
```

Please note that `npm run clean` removes `dist`, `*.tsbuildinfo`, and other
generated files from each package to clean the state for builds.

To build an individual package:

```sh
cd <package-dir> // For example, cd `packages/context`.
npm run build
```

Please note that we are automatically running the build from `pretest` script,
therefore you should not need to run this command as part of your
[red-green-refactor cycle](http://www.jamesshore.com/Blog/Red-Green-Refactor.html).
Expand Down Expand Up @@ -183,8 +202,16 @@ from package-lock files.**
If you ever end up with corrupted or out-of-date package locks, run the
following commands to fix the problem:

To rebuild `package-lock.json` for all packages.

```sh
npm update-package-locks
```

To update `package-lock.json` for a list of packages:

```sh
$ npm run update-package-locks
npm update-package-locks -- --scope <package-name-1> --scope <package-name-2>
```

### Adding dependencies
Expand Down

0 comments on commit ef10c7f

Please sign in to comment.