Skip to content

Commit

Permalink
Updates readme (#3268)
Browse files Browse the repository at this point in the history
  • Loading branch information
abtestingalpha authored Oct 10, 2024
1 parent 2b05e51 commit 174911d
Showing 1 changed file with 17 additions and 29 deletions.
46 changes: 17 additions & 29 deletions packages/synapse-constants/README.md
Original file line number Diff line number Diff line change
@@ -1,53 +1,41 @@
# Synapse Constants

[![npm](https://img.shields.io/npm/v/synapse-constants?style=flat-square)](https://www.npmjs.com/package/synapse-constants)

This package contains the Synapse Protocol Token and Chain Constants


#



## Installation

```bash
npm install synapse-constants
```

With Yarn:

```bash
yarn add synapse-constants
yarn add @synapsecns/synapse-constants
```

## Usage


To restrict the assets and chains that are imported, you can create a "custom bridge list". From the set of all tokens imported from "bridgeable.ts" you can import specific tokens and use that as the custom list you use in your application. The same can be done for chains
## Build

## Usage
For maintenance, when new tokens are added to the bridge the following steps should be taken.
The following command will build the package locally

1. Regenerate bridgeMaps.ts

```bash
yarn maps:generate
```
yarn build
```

2. Update Bridgeable.ts with the new token addresses (check all other variables like decimals/ symbols etc. )
## Usage

3. Repackage and webpack all of the data
Importing supported tokens and chains:

```bash
yarn compile
```js
import { BRIDGABLE_TOKENS, CHAINS } from '@synapsecns/synapse-constants'
```

4. Republish the npm package (make sure to update the version)
Importing a specific token:

```bash
npm publish
```js
import { USDC } from '@synapsecns/synapse-constants'
```

## TODO

TODO:
- add the basic structure of the token type and the chain type to show accessibility for token logos, chain logos, and any additional information.
- [ ] Instructions on adding new chains
- [ ] Instructions on adding new tokens
- [ ] Instructions on generating new token route map

0 comments on commit 174911d

Please sign in to comment.