Skip to content

Commit

Permalink
Rename to @metamask/contract-metadata (MetaMask#603)
Browse files Browse the repository at this point in the history
* Rename to @metamask/contract-metadata

* Cleanup readme

* Add publishconfig
  • Loading branch information
rekmarks authored Nov 10, 2020
1 parent 378df30 commit e20df3b
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 8 deletions.
2 changes: 1 addition & 1 deletion .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ aliases:
npm install

defaults: &defaults
working_directory: ~/eth-contract-metadata
working_directory: ~/contract-metadata

version: 2
jobs:
Expand Down
10 changes: 4 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,19 +1,17 @@
# Ethereum Contract Metadata [![CircleCI](https://circleci.com/gh/MetaMask/eth-contract-metadata.svg?style=svg)](https://circleci.com/gh/MetaMask/eth-contract-metadata)
# @metamask/contract-metadata

[![Greenkeeper badge](https://badges.greenkeeper.io/MetaMask/eth-contract-metadata.svg)](https://greenkeeper.io/)

A mapping of checksummed ethereum addresses to metadata, like names, and images of those addresses' logos.
A mapping of checksummed Ethereum contract addresses to metadata, like names, and images of their logos.

All address keys follow the [EIP 55 address checksum format](https://github.com/ethereum/EIPs/issues/55).

This repository is effectively frozen. We recommend that developers of new tokens use [EIP 747](https://docs.metamask.io/guide/registering-your-token.html) to ask the user's permission to display your tokens in their wallet. This reduces the dangers of airdrop-based phishing, and reduces administrative overhead from managing this list.

## Usage

You can install from npm with `npm install eth-contract-metadata` and use it in your code like this:
You can install from npm with `npm install @metamask/contract-metadata` and use it in your code like this:

```javascript
import contractMap from 'eth-contract-metadata'
import contractMap from '@metamask/contract-metadata'
import ethJSUtil from 'ethereumjs-util'
const { toChecksumAddress } = ethJSUtil

Expand Down
6 changes: 5 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,12 @@
{
"name": "eth-contract-metadata",
"name": "@metamask/contract-metadata",
"version": "1.17.0",
"description": "A mapping of ethereum contract addresses to broadly accepted icons for those addresses.",
"main": "index.js",
"publishConfig": {
"registry": "https://registry.npmjs.org/",
"access": "public"
},
"scripts": {
"test": "node test"
},
Expand Down

0 comments on commit e20df3b

Please sign in to comment.