Skip to content

righteoux/token-lists

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

@uniswap/token-lists

Tests

This package includes a JSON schema for token lists, and TypeScript utilities for working with token lists.

The JSON schema represents the specification for a token list which can be used in the Uniswap Interface.

Validating token lists

This package does not include token list validation. You can easily do this by including a library such as ajv to perform the validation against the JSON schema.

Authoring token lists

Currently, the best way to author token lists is to use an editor that supports JSON schema validation. Most popular code editors do, such as IntelliJ or VSCode. Other editors can be found here.

Once you have set up the JSON schema, you should get inline validation errors, which provide details about each field in the token list schema.

Note that in order for your token list to be able to be used, it must pass JSON schema validation.

Local Development

Below is a list of commands you will probably find useful.

npm start

Runs the project in development/watch mode. Your project will be rebuilt upon changes. TSDX has a special logger for you convenience. Error messages are pretty printed and formatted for compatibility VS Code's Problems tab.

Your library will be rebuilt if you make edits.

npm run build

Bundles the package to the dist folder. The package is optimized and bundled with Rollup into multiple formats (CommonJS, UMD, and ES Module).

npm test

Runs the test watcher (Jest) in an interactive mode. By default, runs tests related to files changed since the last commit.

About

📚 The Token Lists specification

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • TypeScript 100.0%