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

Fix Token program ESM exports #3508

Merged
merged 23 commits into from
Aug 23, 2022
Merged
Show file tree
Hide file tree
Changes from 20 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
2 changes: 1 addition & 1 deletion .github/workflows/pull-request-token.yml
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@ jobs:
js-test:
runs-on: ubuntu-latest
env:
NODE_VERSION: 14.x
NODE_VERSION: 16.x
needs: cargo-test-sbf
steps:
- uses: actions/checkout@v2
Expand Down
File renamed without changes.
5 changes: 3 additions & 2 deletions token/js/.eslintignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
node_modules

docs
lib
test-ledger

package-lock.json
20 changes: 20 additions & 0 deletions token/js/.eslintrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
{
"root": true,
"extends": [
"eslint:recommended",
"plugin:@typescript-eslint/recommended",
"plugin:prettier/recommended"
],
"parser": "@typescript-eslint/parser",
"plugins": [
"@typescript-eslint",
"prettier"
],
"rules": {
"@typescript-eslint/ban-ts-comment": "off",
"@typescript-eslint/no-explicit-any": "off",
"@typescript-eslint/no-unused-vars": "off",
"@typescript-eslint/no-empty-interface": "off",
"@typescript-eslint/consistent-type-imports": "error"
}
}
14 changes: 0 additions & 14 deletions token/js/.eslintrc.json

This file was deleted.

13 changes: 12 additions & 1 deletion token/js/.gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,13 @@
lib
.idea
.vscode
.DS_Store

node_modules

pnpm-lock.yaml
yarn.lock

docs
lib
test-ledger
*.tsbuildinfo
2 changes: 2 additions & 0 deletions token/js/.prettierignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
docs
lib
test-ledger

package-lock.json
21 changes: 15 additions & 6 deletions token/js/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,11 +25,20 @@ Please see [upgrading from 0.1.x](#upgrading-from-0.1.x).
## Install

```shell
yarn add @solana/spl-token
npm install --save @solana/spl-token @solana/web3.js
```
_OR_
```shell
yarn add @solana/spl-token @solana/web3.js
```

## Build from Source

0. Prerequisites

* Node 16+
* NPM 8+

1. Clone the project:
```shell
git clone https://github.com/solana-labs/solana-program-library.git
Expand All @@ -42,27 +51,27 @@ cd solana-program-library/token/js

3. Install the dependencies:
```shell
yarn install
npm install
```

4. Build the library:
```shell
yarn build
npm run build
```

5. Build the on-chain programs:
```shell
yarn test:build-programs
npm run test:build-programs
```

6. Run the tests:
```shell
yarn test
npm run test
```

7. Run the example:
```shell
yarn example
npm run example
```

## Upgrading
Expand Down
Loading