Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Lock web3.js to version 1.x for compatibility #595

Merged
merged 1 commit into from
Nov 6, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions content/courses/intro-to-solana/intro-to-cryptography.md
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ You can use the Solana blockchain from either the browser or node.js with the
to install `@solana/web3.js`

```shell
npm i @solana/web3.js
npm i @solana/web3.js@1
```

We'll cover a lot of
Expand Down Expand Up @@ -171,7 +171,7 @@ Make a new directory, install TypeScript, Solana web3.js and esrun:
mkdir generate-keypair
cd generate-keypair
npm init -y
npm install typescript @solana/web3.js esrun @solana-developers/helpers
npm install typescript @solana/web3.js@1 esrun @solana-developers/helpers@2
```

Make a new file called `generate-keypair.ts`
Expand Down
2 changes: 1 addition & 1 deletion content/courses/intro-to-solana/intro-to-reading-data.md
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ Solana. We'll also install TypeScript and `esrun`, so we can run `.ts` files on
the command line:

```bash
npm install typescript @solana/web3.js esrun
npm install typescript @solana/web3.js@1 esrun
```

### Connect to the Network
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -895,7 +895,7 @@ npm init -y
Install all the required dependencies.

```bash
npm i @solana/web3.js @solana-developers/[email protected]
npm i @solana/web3.js@1 @solana-developers/[email protected]
npm i --save-dev esrun
```
Expand Down
2 changes: 1 addition & 1 deletion content/courses/state-compression/compressed-nfts.md
Original file line number Diff line number Diff line change
Expand Up @@ -647,7 +647,7 @@ cd cnft-demo
Install all the required dependencies

```bash
npm i @solana/web3.js @solana-developers/[email protected] @metaplex-foundation/mpl-token-metadata @metaplex-foundation/mpl-bubblegum @metaplex-foundation/digital-asset-standard-api @metaplex-foundation/umi-bundle-defaults
npm i @solana/web3.js@1 @solana-developers/[email protected] @metaplex-foundation/mpl-token-metadata @metaplex-foundation/mpl-bubblegum @metaplex-foundation/digital-asset-standard-api @metaplex-foundation/umi-bundle-defaults

npm i --save-dev esrun
```
Expand Down
2 changes: 1 addition & 1 deletion content/courses/token-extensions/close-mint.md
Original file line number Diff line number Diff line change
Expand Up @@ -213,7 +213,7 @@ Next, we'll need to add our dependencies. Run the following to install the
required packages:

```bash
npm i @solana-developers/helpers @solana/spl-token @solana/web3.js esrun dotenv typescript
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this one looks like it has a mistake

npm i @solana-developers/helpers@2 @solana/spl-token @solana/web3.js@1 esrun dotenv typescript
```

Create a directory named `src`. In this directory, create a file named
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -223,7 +223,7 @@ Next, we'll need to add our dependencies. Run the following to install the
required packages:

```bash
npm i @solana-developers/helpers @solana/spl-token @solana/web3.js esrun dotenv typescript
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this one looks like it has a mistake

npm i @solana-developers/helpers@2 @solana/spl-token @solana/web3.js@1 esrun dotenv typescript
```

Create a directory named `src`. In this directory, create a file named
Expand Down
2 changes: 1 addition & 1 deletion content/courses/token-extensions/immutable-owner.md
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ Next, we'll need to add our dependencies. Run the following to install the
required packages:

```bash
npm i @solana-developers/helpers @solana/spl-token @solana/web3.js esrun dotenv typescript
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this one looks like it has a mistake

npm i @solana-developers/helpers@2 @solana/spl-token @solana/web3.js@1 esrun dotenv typescript
```

Create a directory named `src`. In this directory, create a file named
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -213,7 +213,7 @@ Next, we'll need to add our dependencies. Run the following to install the
required packages:

```bash
npm i @solana-developers/helpers @solana/spl-token @solana/web3.js esrun dotenv typescript
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this one looks like it has a mistake

npm i @solana-developers/helpers@2 @solana/spl-token @solana/web3.js@1 esrun dotenv typescript
```

Create a directory named `src`. In this directory, create a file named
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ Next, we'll need to add our dependencies. Run the following to install the
required packages:

```bash
npm i @solana-developers/helpers @solana/spl-token @solana/web3.js esrun dotenv typescript
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this one looks like it has a mistake

npm i @solana-developers/helpers@2 @solana/spl-token @solana/web3.js@1 esrun dotenv typescript
```

Create a directory named `src`. In this directory, create a file named
Expand Down
2 changes: 1 addition & 1 deletion content/courses/token-extensions/permanent-delegate.md
Original file line number Diff line number Diff line change
Expand Up @@ -250,7 +250,7 @@ Next, we'll need to add our dependencies. Run the following to install the
required packages:

```bash
npm i @solana-developers/helpers @solana/spl-token @solana/web3.js esrun
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this one looks like it has a mistake

npm i @solana-developers/helpers@2 @solana/spl-token @solana/web3.js@1 esrun
```

Create a directory named `src`. In this directory, create a file named
Expand Down
2 changes: 1 addition & 1 deletion content/courses/token-extensions/required-memo.md
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,7 @@ Next, we'll need to add our dependencies. Run the following to install the
required packages:

```bash
npm i @solana-developers/helpers @solana/spl-token @solana/web3.js esrun dotenv typescript
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this one looks like it has a mistake

npm i @solana-developers/helpers@2 @solana/spl-token @solana/web3.js@1 esrun dotenv typescript
```

Create a directory named `src`. In this directory, create a file named
Expand Down
2 changes: 1 addition & 1 deletion content/courses/token-extensions/transfer-fee.md
Original file line number Diff line number Diff line change
Expand Up @@ -459,7 +459,7 @@ Next, we'll need to add our dependencies. Run the following to install the
required packages:

```bash
npm i @solana-developers/helpers @solana/spl-token @solana/web3.js esrun dotenv typescript
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this one looks like it has a mistake

npm i @solana-developers/helpers@2 @solana/spl-token @solana/web3.js@1 esrun dotenv typescript
```

Create a directory named `src`. In this directory, create a file named
Expand Down
2 changes: 1 addition & 1 deletion content/courses/tokens-and-nfts/nfts-with-metaplex.md
Original file line number Diff line number Diff line change
Expand Up @@ -345,7 +345,7 @@ Solana.
To begin, make a new folder and install the relevant dependencies:

```bash
npm i @solana/web3.js npm i @solana/web3.js npm i @solana-developers/helpers npm i @metaplex-foundation/mpl-token-metadata npm i @metaplex-foundation/umi-bundle-defaults npm i @metaplex-foundation/umi-uploader-irys npm i --save-dev esrun
npm i @solana/web3.js@1 @solana-developers/helpers@2 @metaplex-foundation/mpl-token-metadata @metaplex-foundation/umi-bundle-defaults @metaplex-foundation/umi-uploader-irys esrun
```

Then create a file called `create-metaplex-collection.ts`, and add our imports:
Expand Down
2 changes: 1 addition & 1 deletion content/courses/tokens-and-nfts/token-program.md
Original file line number Diff line number Diff line change
Expand Up @@ -464,7 +464,7 @@ Assuming you already have a `.env` file with a `SECRET_KEY` setup per
[Cryptography fundamentals](/content/courses/intro-to-solana/intro-to-cryptography.md).

```bash
npm i @solana/web3.js @solana/spl-token @solana-developers/helpers esrun
npm i @solana/web3.js@1 @solana/spl-token @solana-developers/helpers@2 esrun
```

#### Create the Token Mint
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1085,7 +1085,7 @@ Throw this command into your terminal to install all the `wallet-adapter` stuff
we need:
```shell
yarn add react @solana/web3.js \
yarn add react @solana/web3.js@1 \
@solana/wallet-adapter-base @solana/wallet-adapter-react \
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

do we need to pin any of the wallet adapter packages? either in these install command or in their respective packages?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I hope not, but probably.

@solana/wallet-adapter-react-ui @solana/wallet-adapter-wallets
```
Expand Down
2 changes: 1 addition & 1 deletion content/guides/getstarted/local-rust-hello-world.md
Original file line number Diff line number Diff line change
Expand Up @@ -251,7 +251,7 @@ For macOS you can
Install the Solana web3.js library and the Solana helpers library:

```shell
npm install @solana/web3.js @solana-developers/helpers
npm install @solana/web3.js@1 @solana-developers/helpers@2
```

Create a new file called `client.mjs` and add the following code:
Expand Down
2 changes: 1 addition & 1 deletion content/guides/javascript/compressed-nfts.md
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ Using your preferred package manager (e.g. npm, yarn, pnpm, etc), install these
packages into your project:

```shell
yarn add @solana/web3.js @solana/spl-token @solana/spl-account-compression
yarn add @solana/web3.js@1 @solana/spl-token @solana/spl-account-compression
```

```shell
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ Install these packages to your Next.js project using your preferred node package
manager:

```shell
npm install @solana/web3.js \
npm install @solana/web3.js@1 \
@solana/wallet-adapter-base \
@solana/wallet-adapter-react \
@solana/wallet-adapter-react-ui \
Expand Down
4 changes: 2 additions & 2 deletions docs/clients/javascript.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,13 +34,13 @@ For the full list of terms, see
#### yarn

```shell
yarn add @solana/web3.js
yarn add @solana/web3.js@1
```

#### npm

```shell
npm install --save @solana/web3.js
npm install --save @solana/web3.js@1
```

#### Bundle
Expand Down
Loading