Skip to content

Commit f7e12a3

Browse files
committed
update: README instructions
1 parent 8e7078f commit f7e12a3

File tree

1 file changed

+37
-1
lines changed

1 file changed

+37
-1
lines changed

README.md

Lines changed: 37 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,16 +70,52 @@ git fetch upstream
7070
git merge upstream/dev
7171
```
7272

73-
2. Install dependencies
73+
2. Prepare package manager
7474

7575
We've upgraded to pnpm to speed up development experience and improve dependency management.
7676

7777
We recommend using a [node manager such as nvm](https://github.com/nvm-sh/nvm?tab=readme-ov-file#intro) to use multiple node versions in your system. We have a `.nvmrc` file that declares the canonical Node.js version for this project. If you use `nvm`, you can run `nvm use` to automatically switch to the correct version.
7878

79+
**Use current node version (recommended)**
80+
81+
```sh
82+
nvm use
83+
```
84+
85+
Corepack is a tool that allows you to use package managers like pnpm, yarn, and npm without needing to install them globally. It ensures that the correct version of the package manager is used for your project.
86+
87+
**Enable corepack (recommended):**
88+
89+
```sh
90+
corepack enable
91+
```
92+
93+
3. Install dependencies
94+
7995
```sh
8096
pnpm install
8197
```
8298

99+
#### Migrating from yarn to pnpm
100+
101+
If you previously used `yarn` to install dependencies, you can safely migrate to `pnpm` by running the following commands:
102+
103+
```sh
104+
# Remove yarn.lock file
105+
rm yarn.lock
106+
107+
# Remove node_modules directory
108+
rm -rf node_modules
109+
110+
# Clean yarn cache (optional)
111+
yarn cache clean
112+
113+
# Install dependencies with pnpm
114+
pnpm install
115+
```
116+
117+
This will cleanly switch the project working directory from yarn to pnpm without leaving any residual yarn configuration.
118+
83119
### 4. Make awesome changes!
84120

85121
1. Create new branch for your changes

0 commit comments

Comments
 (0)