# angular-monorepo-packages-test

> This repository exists to demonstrate setting up Lerna and providing contribution guidelines for projects using Lerna.

Latest version **0.0.0** (published 2020-04-20) · 0 weekly downloads

## Install

```sh
npm install angular-monorepo-packages-test
pnpm add angular-monorepo-packages-test
yarn add angular-monorepo-packages-test
bun add angular-monorepo-packages-test
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.0.0 |
| Published | 2020-04-20 |
| First published | 2020-04-20 |
| Weekly downloads | 0 |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 11 |
| Unpacked size | 60.2 KB |
| Known vulnerabilities | 0 (+24 in 4 direct dependencies) |
| Install scripts | no |
| Maintainers | alonewarrior |

## Links

- npm: https://www.npmjs.com/package/angular-monorepo-packages-test
- npm.io page: https://npm.io/package/angular-monorepo-packages-test

## Dependencies (11)

- [rxjs](https://npm.io/package/rxjs.md) ^6.5.5
- [tslib](https://npm.io/package/tslib.md) ^1.7.1
- [zone.js](https://npm.io/package/zone.js.md) ^0.10.3
- [@angular/core](https://npm.io/package/@angular/core.md) ^9.1.2
- [@angular/forms](https://npm.io/package/@angular/forms.md) ^9.1.2
- [@angular/common](https://npm.io/package/@angular/common.md) ^9.1.2
- [@angular/router](https://npm.io/package/@angular/router.md) ^9.1.2
- [@angular/compiler](https://npm.io/package/@angular/compiler.md) ^9.1.2
- [@angular/animations](https://npm.io/package/@angular/animations.md) ^9.1.2
- [@angular/platform-browser](https://npm.io/package/@angular/platform-browser.md) ^9.1.2
- [@angular/platform-browser-dynamic](https://npm.io/package/@angular/platform-browser-dynamic.md) ^9.1.2

## Recent versions

- 0.0.0 (latest) — 2020-04-20

## README

# Angular Monorepo Packages Test
This repository exists to demonstrate setting up Lerna and providing contribution guidelines for projects using Lerna.

1. Setup Lerna
2. Contributing Guidelines

Important links:

## 1. Setup with Lerna

For more information on Lerna, read up on their source repo docs: https://github.com/lerna/lerna

1. Setup with Lerna
    1. Init Lerna
    2. Modify lerna.json
    3. Modify package.json
    4. Modify each project's package.json
    5. Modify each project's ng-package.json/ng-package.prod.json


### 1.i. Init Lerna
Run `npx lerna init` within the main project directory (not 'projects').

### 1.ii. Modify lerna.json
Use the following for the lerna.json file. These configurations can be modified as needed.

    {
      "packages": [
        "projects/*"
      ],
      "command": {
        "publish": {
          "contents": "dist",
          "conventional-commits": true
        },
        "version": {
          "message": "chore(release): publish %s",
          "conventional-commits": true,
          "push": false
        },
        "bootstrap": {
          "npmClientArgs": ["--no-package-lock"]
        }
      },
      "version": "independent"
    }



### 1.iii. Modify package.json
Add the following scripts to the package.json


`"lerna-version": "lerna version --yes --conventional-commits",`

`"postversion": "lerna run build",`


The following are unnecessary within TFS/Azure DevOps at present:

`"lerna-publish": "lerna publish --yes --conventional-commits",`

`"prepublish": "lerna run build",`

### 1.iv. Modify each project's package.json

#### Modify name for scope
If using scoping for the project names, change the name to include the scope:

Before:
`"name": "my-project"`

After:
`"name": "@my-scope/my-project"`

#### Add build script
Add the following script to the package.json

```
{
    ...
    "scripts": {
        "build": "ng build my-project --prod"
    },
    ...
}
```


### 1.v. Modify each project's ng-package.json/ng-package.prod.json
Modify the `dest` property in ng-package.json and ng-package.prod.json to 

```
{
    "dest": "./dist",
    ...
}
```


## 2. Contributing Guidelines

For more details on the git commit guidelines and their source, check out:  https://github.com/angular/angular.js/blob/master/DEVELOPERS.md#-git-commit-guidelines

---
_Source: https://npm.io/package/angular-monorepo-packages-test · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
