Skip to content

Commit

Permalink
remove unnecessary deps, update example
Browse files Browse the repository at this point in the history
  • Loading branch information
mdtanrikulu committed Dec 18, 2023
1 parent 20ee5bc commit 28a97aa
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 15 deletions.
8 changes: 3 additions & 5 deletions example/browser.js
Original file line number Diff line number Diff line change
Expand Up @@ -28,11 +28,9 @@ const notFoundImage =
const provider = new StaticJsonRpcProvider(
`https://mainnet.infura.io/v3/${process.env.INFURA_KEY}`
);
const avt = new AvatarResolver(provider,
{ apiKey: {
opensea: process.env.OPENSEA_KEY
}}
);
const avt = new AvatarResolver(provider, {
apiKey: { opensea: process.env.OPENSEA_KEY },
});
for (let ens of ensNames) {
avt
.getMetadata(ens)
Expand Down
2 changes: 1 addition & 1 deletion example/build.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ require('esbuild')
},
outfile: 'example/dist/index.js',
define: {
"process": `{
process: `{
"env": {
"INFURA_KEY": '${process.env.INFURA_KEY}',
"OPENSEA_KEY": '${process.env.OPENSEA_KEY}'
Expand Down
2 changes: 1 addition & 1 deletion example/node.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ const IPFS = 'https://cf-ipfs.com';
const provider = new StaticJsonRpcProvider(
`https://mainnet.infura.io/v3/${process.env.INFURA_KEY}`
);
const avt = new AvatarResolver(provider, { ipfs: IPFS});
const avt = new AvatarResolver(provider, { ipfs: IPFS, apiKey: { opensea: process.env.OPENSEA_KEY }});
avt
.getMetadata(ensName)
.then(metadata => {
Expand Down
2 changes: 0 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -60,11 +60,9 @@
"@types/url-join": "^4.0.1",
"dotenv": "^16.0.0",
"esbuild": "^0.14.21",
"husky": "^7.0.4",
"nock": "^13.2.2",
"size-limit": "^7.0.5",
"tsdx": "^0.14.1",
"tslib": "^2.3.1",
"typescript": "^4.5.5"
},
"dependencies": {
Expand Down
7 changes: 1 addition & 6 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -3832,11 +3832,6 @@ humanize-duration@^3.15.3:
resolved "https://registry.npmjs.org/humanize-duration/-/humanize-duration-3.27.1.tgz"
integrity sha512-jCVkMl+EaM80rrMrAPl96SGG4NRac53UyI1o/yAzebDntEY6K6/Fj2HOjdPg8omTqIe5Y0wPBai2q5xXrIbarA==

husky@^7.0.4:
version "7.0.4"
resolved "https://registry.npmjs.org/husky/-/husky-7.0.4.tgz"
integrity sha512-vbaCKN2QLtP/vD4yvs6iz6hBEo6wkSzs8HpRah1Z6aGmF2KW5PdYuAd7uX5a+OyBZHBhd+TFLqgjUgytQr4RvQ==

[email protected], iconv-lite@^0.4.24:
version "0.4.24"
resolved "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.4.24.tgz"
Expand Down Expand Up @@ -6760,7 +6755,7 @@ tslib@^1.8.1, tslib@^1.9.0, tslib@^1.9.3:
resolved "https://registry.npmjs.org/tslib/-/tslib-1.14.1.tgz"
integrity sha512-Xni35NKzjgMrwevysHTCArtLDpPvye8zV/0E4EyYn43P7/7qvQwPh9BGkHewbMulVntbigmcT7rdX3BNo9wRJg==

tslib@^2.0.3, tslib@^2.3.1:
tslib@^2.0.3:
version "2.3.1"
resolved "https://registry.npmjs.org/tslib/-/tslib-2.3.1.tgz"
integrity sha512-77EbyPPpMz+FRFRuAFlWMtmgUWGe9UOG2Z25NqCwiIjRhOf5iKGuzSe5P2w1laq+FkRy4p+PCuVkJSGkzTEKVw==
Expand Down

0 comments on commit 28a97aa

Please sign in to comment.