|
6 | 6 | - [Table of Contents](#table-of-contents) |
7 | 7 | - [Pre-requisites:](#pre-requisites) |
8 | 8 | - [Consuming Unity packages in your separate project:](#consuming-unity-packages-in-your-separate-project) |
9 | | - - [How to use the private package registry:](#how-to-use-the-private-package-registry) |
| 9 | + - [If you want to clone the entire repository and work on the packages:](#if-you-want-to-clone-the-entire-repository-and-work-on-the-packages) |
10 | 10 | - [TROUBLESHOOTING ERRORS](#troubleshooting-errors) |
11 | 11 | - [Packages in this repository](#packages-in-this-repository) |
12 | 12 | - [Cookie Consent](#cookie-consent) |
@@ -68,19 +68,30 @@ Follow the steps below if you want to consume the Unity packages in your own pro |
68 | 68 | 2. Install the package using npm: |
69 | 69 | ```npm install @asu/<package-name>``` |
70 | 70 |
|
71 | | -If using yarn2+, follow the steps below. |
| 71 | +If using yarn2+: |
| 72 | + |
| 73 | +1. Add the following to your .yarnrc.yml file: |
| 74 | +```Yaml |
| 75 | +npmScopes: |
| 76 | + asu: |
| 77 | + npmAuthToken: "${GITHUB_AUTH_TOKEN-fallback}" |
| 78 | + npmPublishRegistry: "https://npm.pkg.github.com" |
| 79 | + npmRegistryServer: "https://npm.pkg.github.com" |
| 80 | +``` |
| 81 | +2. Add the following to your .env.yarn file: |
| 82 | +```env |
| 83 | +GITHUB_AUTH_TOKEN=YOUR_AUTH_TOKEN_HERE |
| 84 | +``` |
72 | 85 |
|
73 | 86 |
|
74 | | -## How to use the private package registry: |
| 87 | +## If you want to clone the entire repository and work on the packages: |
75 | 88 |
|
76 | 89 | The ASU Unity Design System packages are published to GitHub's package registry. This is not the same as the NPM registry. To use the packages, you need to belong to ASU's GitHub organization and to configure your local NPM to use this registry. |
77 | 90 |
|
78 | 91 | 1. Clone the monorepo using ```git clone``` or download the zip file from GitHub. |
79 | 92 | 2. If you don't already have it [request access to the Unity Design System GitHub Repo](https://asu.edu/webservices). |
80 | 93 | 3. Once you have access, there is a ```.env.yarn.example``` file in the root of this project with the correct environment variable name used in the ```.yarnrc.yml``` file. Make a copy and name it ```.env.yarn``` and replace the ```YOUR_AUTH_TOKEN_HERE``` with a [GitHub Personal Access Token](https://docs.github.com/en/packages/working-with-a-github-packages-registry/working-with-the-npm-registry#authenticating-to-github-packages) to have a project-based configuration for adding Unity package dependencies to your project. |
81 | 94 | 4. The environment variable in the ```.env.yarn``` file is used in the ```.yarnrc.yml``` file to authenticate with the GitHub package registry. The ```.yarnrc.yml``` file is used by Yarn to configure the package registry. |
82 | | -5. Test installing packages using yarn or npm inside of another NPM project: |
83 | | -```yarn add @asu/unity-bootstrap-theme``` |
84 | 95 |
|
85 | 96 | ### TROUBLESHOOTING ERRORS |
86 | 97 |
|
@@ -131,7 +142,7 @@ Previously deprecated packages were located inside the `packages-disabled` folde |
131 | 142 | 6. [app-new-template](https://github.com/ASU/asu-unity-stack/tree/86368e5c656108169fe27cbc405e43c2cebae968/packages-disabled/app-new-template) |
132 | 143 | 7. [component-forms](https://github.com/ASU/asu-unity-stack/tree/86368e5c656108169fe27cbc405e43c2cebae968/packages-disabled/component-forms) |
133 | 144 | 8. [maps](https://github.com/ASU/asu-unity-stack/tree/86368e5c656108169fe27cbc405e43c2cebae968/packages-disabled/maps) |
134 | | -9. component-carousel |
| 145 | +9. [component-carousel](https://github.com/ASU/asu-unity-stack/blob/b5cc906aa26148208a0458355b9bf6d2f6bec149/packages/component-carousel/package.json) |
135 | 146 |
|
136 | 147 |
|
137 | 148 | ## Package Multi Output Targets |
|
0 commit comments