Skip to content

Commit

Permalink
docs: update package docs with pnpm information (#2675)
Browse files Browse the repository at this point in the history
  • Loading branch information
matheusps authored and artursantiago committed Feb 14, 2025
1 parent 762ad0f commit 49520b4
Show file tree
Hide file tree
Showing 8 changed files with 25 additions and 25 deletions.
2 changes: 1 addition & 1 deletion .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@

**Dependencies**

- [ ] Committed the `yarn.lock` file when there were changes to the packages
- [ ] Committed the `pnpm-lock.yaml` file when there were changes to the packages

**Documentation**

Expand Down
16 changes: 8 additions & 8 deletions CONTRIBUTING.MD
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,9 @@ Before you begin, make sure you have the following installed on your local machi

- [Git](https://git-scm.com)
- [Node.js](https://nodejs.org/en)
- [Yarn](https://yarnpkg.com/)
- [Pnpm](https://pnpm.io)
- [Turbo](https://turbo.build/repo/docs/getting-started/installation#installing-turbo)
- Your Preferred Code Editor (VSCode, Sublime, etc.)
- Your Preferred Code Editor (VSCode, Sublime, Zed, etc.)

## 2. Getting Started

Expand All @@ -28,17 +28,17 @@ Fork the repository (click the <kbd>Fork</kbd> button at the top right of

### Setting Up the Environment

1. Run `yarn` at the root of the repository.
1. Run `pnpm i` at the root of the repository.

2. Run `yarn build` at the root of the repository.
2. Run `pnpm build` at the root of the repository.

3. Run `yarn turbo run dev --filter={packageName}` to run a package individually.
3. Run `pnpm turbo run dev --filter={packageName}` to run a package individually.

> For example, if you want to run the `@faststore/core` package, at the root of the repository run:
>
> `yarn turbo run dev --filter=@faststore/core`
> `pnpm turbo run dev --filter=@faststore/core`
**Note**: If you encounter issues during the setup process, please check if your current version of Yarn, Turbo, and Node.js are matching the versions specified in the package.json file.
**Note**: If you encounter issues during the setup process, please check if your current version of Pnpm, Turbo, and Node.js are matching the versions specified in the package.json file.

## 3. Working on an Issue

Expand Down Expand Up @@ -67,7 +67,7 @@ To test your changes in a store, you will need to create a pull request (for mor
<img width="502" alt="image" src="https://vtexhelp.vtexassets.com/assets/docs/src/fs-package-local-install-cli___692a64eba8c0b3745c468176bfc610fb.png
"></img>

4. Run `yarn` to install the updates and test your changes in the store.
4. Run `pnpm` to install the updates and test your changes in the store.

**Note**: This link is intended for testing purposes only. Please avoid using it in your store. Once the published version of your package is available, make sure to update the link accordingly.

Expand Down
4 changes: 2 additions & 2 deletions packages/api/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,10 +23,10 @@

## Installation

From the command line in your project directory, run yarn add `@faststore/api`.
From the command line in your project directory, run pnpm add `@faststore/api`.

```cmd
yarn add @faststore/api
pnpm add @faststore/api
```

## Usage
Expand Down
2 changes: 1 addition & 1 deletion packages/cli/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ DESCRIPTION
Creates a discovery folder based on the starter.store template.
EXAMPLES
$ yarn faststore create discovery
$ pnpm faststore create discovery
```

_See code: [dist/commands/create.js](https://github.com/vtex/faststore/blob/v3.15.2/dist/commands/create.js)_
Expand Down
14 changes: 7 additions & 7 deletions packages/core/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,20 +14,20 @@ This starter ships the main FastStore configuration files to get your store up a

1. **Install dependencies**

> PS: you can install dependencies using the package manager of your choosing. In this guide, we'll be using `yarn` as an example.
> PS: you can install dependencies using the package manager of your choosing. In this guide, we'll be using `pnpm` as an example.
Install dependencies with yarn
Install dependencies with pnpm

```shell
yarn
pnpm i
```

2. **Start developing**

Navigate into your new site’s directory and start it up.

```shell
yarn dev
pnpm dev
```

3. **Open the source code and start editing!**
Expand Down Expand Up @@ -167,18 +167,18 @@ We use [graphql-codegen](https://www.graphql-code-generator.com/) to pre-process
This means we can statically analyze your code in search of bugs and secure your graphql server before each deploy. If, however you need to change any GraphQL Fragment, Query or Mutation, you will need to regenerate the whole thing. To do this, open your terminal and type

```sh
$ yarn dev
$ pnpm dev
```

Now, after the nextjs development server is up and running, open another terminal and run

```sh
$ yarn generate
$ pnpm generate
```

That's it! you have just regenerated all graphql queries/fragments for your application and the new data you requested should be available to your component.

> Pro tip: Pass `-w` to the `yarn generate` command so it watches for changes and you don't need to run this command multiple times.
> Pro tip: Pass `-w` to the `pnpm generate` command so it watches for changes and you don't need to run this command multiple times.
## CMS Integration

Expand Down
4 changes: 2 additions & 2 deletions packages/graphql-utils/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ Installing this plugin may vary depending on your setup. The instructions below
To install, just

```sh
$ yarn add @faststore/graphql-utils
$ pnpm add @faststore/graphql-utils
```

> Note. Also make sure to install [graphql codegen cli](https://www.graphql-code-generator.com/docs/getting-started/installation)
Expand All @@ -71,7 +71,7 @@ path/to/persisted.json:
Now, open your terminal and run:

```sh
$ yarn run graphql-codegen
$ pnpm run graphql-codegen
```

This should generate a `persisted.json` file containing a map between operation names and queries. Use this file o your graphql server to filter and run queries.
Expand Down
4 changes: 2 additions & 2 deletions packages/sdk/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,10 +29,10 @@

## Installation

From the command line in your project directory, run yarn add `@faststore/sdk`.
From the command line in your project directory, run pnpm add `@faststore/sdk`.

```cmd
yarn add @faststore/sdk
pnpm add @faststore/sdk
```

## Usage
Expand Down
4 changes: 2 additions & 2 deletions packages/ui/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,10 +29,10 @@

## Installation

From the command line in your project directory, run yarn add `@faststore/ui`.
From the command line in your project directory, run pnpm add `@faststore/ui`.

```cmd
yarn add @faststore/ui
pnpm add @faststore/ui
```

## Usage
Expand Down

0 comments on commit 49520b4

Please sign in to comment.