{"_id":"@b0rza/gitcoin-chain-data","_rev":"3-b76bcdc199e63ce54948e7a54b8f9c1b","name":"@b0rza/gitcoin-chain-data","dist-tags":{"latest":"1.1.2"},"versions":{"1.0.40":{"name":"@b0rza/gitcoin-chain-data","version":"1.0.40","keywords":["gitcoin","chain","data"],"author":{"name":"jaxcoder"},"license":"MIT","_id":"@b0rza/gitcoin-chain-data@1.0.40","maintainers":[{"name":"b0rza","email":"apps.npm@aldalo.me"}],"homepage":"https://github.com/b0rza/gitcoin-chain-data#readme","bugs":{"url":"https://github.com/b0rza/gitcoin-chain-data/issues"},"dist":{"shasum":"5cea573a4f6e7f29214406fd091f9e062f403399","tarball":"https://registry.npmjs.org/@b0rza/gitcoin-chain-data/-/gitcoin-chain-data-1.0.40.tgz","fileCount":109,"integrity":"sha512-h3yPjxlbRavPrFQV2Ex4qe+SavSVKRp+JbcKdEb3xV6RrVlGe0S3IGx6Gph+vkzrTjSi7aSWT5+DCH8Zx+TbcA==","signatures":[{"sig":"MEUCIGYSaWRzJQ2NGkMsP9lxbjXq3fcDW4/0SDPIkL00FATCAiEA3hGOW3m8LzaFh5cXpoRVYnU79My0naMdOCE0Xwn1+Ro=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":8368196},"main":"dist/index.js","tsup":{"dts":true,"clean":true,"entry":["./src/index.ts"],"bundle":true,"sourcemap":true,"splitting":false},"types":"dist/index.d.ts","engines":{"npm":">=8.5.5","node":">=16.15.0"},"gitHead":"5863af7d964cd8398b5573aa2ce4ad95e9d5c604","scripts":{"build":"rm -rf dist && tsup && tsc && cp -rf src/data/* dist/data","new-chain":"node scripts/newChain.ts"},"_npmUser":{"name":"b0rza","email":"apps.npm@aldalo.me"},"repository":{"url":"git+https://github.com/b0rza/gitcoin-chain-data.git","type":"git"},"_npmVersion":"10.8.2","description":"A library for interacting with the Gitcoin chain data.","directories":{},"_nodeVersion":"20.17.0","dependencies":{"viem":"^2.9.32"},"_hasShrinkwrap":false,"devDependencies":{"tsup":"^8.0.2","cpy-cli":"^5.0.0","@types/bun":"latest","@types/react":"^18.3.1"},"peerDependencies":{"typescript":"^5.0.0"},"_npmOperationalInternal":{"tmp":"tmp/gitcoin-chain-data_1.0.40_1728895815323_0.19040025939701288","host":"s3://npm-registry-packages"}},"1.1.0":{"name":"@b0rza/gitcoin-chain-data","version":"1.1.0","keywords":["gitcoin","chain","data"],"author":{"name":"jaxcoder"},"license":"MIT","_id":"@b0rza/gitcoin-chain-data@1.1.0","maintainers":[{"name":"b0rza","email":"apps.npm@aldalo.me"}],"homepage":"https://github.com/b0rza/gitcoin-chain-data#readme","bugs":{"url":"https://github.com/b0rza/gitcoin-chain-data/issues"},"dist":{"shasum":"e849b10d1c339cf9ca07a371f68bc5c48b0db7d5","tarball":"https://registry.npmjs.org/@b0rza/gitcoin-chain-data/-/gitcoin-chain-data-1.1.0.tgz","fileCount":109,"integrity":"sha512-3wCu9bV5bQxiL36g5LZKbUun5Iq9VDH6Zva+sQgCNQgF3WEJZwdPr2J5S4GeUGKnDuD6l9Ji2y6ooqo9K/T49A==","signatures":[{"sig":"MEYCIQDbO4w/XvGDq0v06W88y1bU8b84FnyMDCMNbOXMrzoLSgIhAO0vfKcGojFHJzVmHYzcVptKUP4JDxDI+n4lO2oi5Jjf","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":8368195},"main":"dist/index.js","tsup":{"dts":true,"clean":true,"entry":["./src/index.ts"],"bundle":true,"sourcemap":true,"splitting":false},"types":"dist/index.d.ts","engines":{"npm":">=8.5.5","node":">=16.15.0"},"gitHead":"b51b79b7502ea184d98439ee80d8e31243937081","scripts":{"build":"rm -rf dist && tsup && tsc && cp -rf src/data/* dist/data","new-chain":"node scripts/newChain.ts"},"_npmUser":{"name":"b0rza","email":"apps.npm@aldalo.me"},"repository":{"url":"git+https://github.com/b0rza/gitcoin-chain-data.git","type":"git"},"_npmVersion":"10.8.2","description":"A library for interacting with the Gitcoin chain data.","directories":{},"_nodeVersion":"20.17.0","dependencies":{"viem":"^2.9.32"},"_hasShrinkwrap":false,"devDependencies":{"tsup":"^8.0.2","cpy-cli":"^5.0.0","@types/bun":"latest","@types/react":"^18.3.1"},"peerDependencies":{"typescript":"^5.0.0"},"_npmOperationalInternal":{"tmp":"tmp/gitcoin-chain-data_1.1.0_1728980710165_0.3855039548805548","host":"s3://npm-registry-packages"}},"1.1.1":{"name":"@b0rza/gitcoin-chain-data","version":"1.1.1","keywords":["gitcoin","chain","data"],"author":{"name":"jaxcoder"},"license":"MIT","_id":"@b0rza/gitcoin-chain-data@1.1.1","maintainers":[{"name":"b0rza","email":"apps.npm@aldalo.me"}],"homepage":"https://github.com/b0rza/gitcoin-chain-data#readme","bugs":{"url":"https://github.com/b0rza/gitcoin-chain-data/issues"},"dist":{"shasum":"db176ac78dee4bc9e993a0d165721e3ed309d531","tarball":"https://registry.npmjs.org/@b0rza/gitcoin-chain-data/-/gitcoin-chain-data-1.1.1.tgz","fileCount":111,"integrity":"sha512-dFWWQEUzTAkFLgGfhyYEdz3EoNNRi32qZ9IndfeHSMW8rwGlHQHTb22g+77TmpvwejmnyXGJs893bIi2/noHwA==","signatures":[{"sig":"MEUCIQDNkQEyfolekLgPiPwPg68X3wGwqpuYnPh2xPwp+tMlXwIgbm4T6T/63euxdwsDLwfwE69Lr+OIToyIicWMTywsCms=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":8370650},"main":"dist/index.js","tsup":{"dts":true,"clean":true,"entry":["./src/index.ts"],"bundle":true,"sourcemap":true,"splitting":false},"types":"dist/index.d.ts","engines":{"npm":">=8.5.5","node":">=16.15.0"},"gitHead":"09ad54b53ab177ceb6e29a2de9f4ea80acad0145","scripts":{"build":"rm -rf dist && tsup && tsc && cp -rf src/data/* dist/data","new-chain":"node scripts/newChain.ts"},"_npmUser":{"name":"b0rza","email":"apps.npm@aldalo.me"},"repository":{"url":"git+https://github.com/b0rza/gitcoin-chain-data.git","type":"git"},"_npmVersion":"10.8.2","description":"A library for interacting with the Gitcoin chain data.","directories":{},"_nodeVersion":"20.17.0","dependencies":{"viem":"^2.9.32"},"_hasShrinkwrap":false,"devDependencies":{"tsup":"^8.0.2","cpy-cli":"^5.0.0","@types/bun":"latest","@types/react":"^18.3.1"},"peerDependencies":{"typescript":"^5.0.0"},"_npmOperationalInternal":{"tmp":"tmp/gitcoin-chain-data_1.1.1_1728980953328_0.09524420345147266","host":"s3://npm-registry-packages"}},"1.1.2":{"name":"@b0rza/gitcoin-chain-data","version":"1.1.2","main":"dist/index.js","types":"dist/index.d.ts","engines":{"npm":">=8.5.5","node":">=16.15.0"},"author":{"name":"jaxcoder"},"license":"MIT","keywords":["gitcoin","chain","data"],"scripts":{"build":"rm -rf dist && tsup && tsc && cp -rf src/data/* dist/data","new-chain":"node scripts/newChain.ts"},"dependencies":{"viem":"^2.9.32"},"devDependencies":{"@types/bun":"latest","@types/react":"^18.3.1","cpy-cli":"^5.0.0","tsup":"^8.0.2"},"peerDependencies":{"typescript":"^5.0.0"},"repository":{"type":"git","url":"git+https://github.com/b0rza/gitcoin-chain-data.git"},"bugs":{"url":"https://github.com/b0rza/gitcoin-chain-data/issues"},"tsup":{"entry":["./src/index.ts"],"splitting":false,"sourcemap":true,"clean":true,"bundle":true,"dts":true},"description":"A library for interacting with the Gitcoin chain data.","homepage":"https://github.com/b0rza/gitcoin-chain-data#readme","_id":"@b0rza/gitcoin-chain-data@1.1.2","gitHead":"927546cdb894ba8b8a0bb16eeb0b4ebac27e1435","_nodeVersion":"20.17.0","_npmVersion":"10.8.2","dist":{"integrity":"sha512-7ARJuauPtMnD0HmBXvcPVKJO4ZQJY008qLKXUKRJ5wfDiY/i9/kQFdSgQp8rPsP47gbCKXnGkI0M1dteh8sBeg==","shasum":"8f79c1b6d6eab7105cee6b22c9c1bc8025f1b397","tarball":"https://registry.npmjs.org/@b0rza/gitcoin-chain-data/-/gitcoin-chain-data-1.1.2.tgz","fileCount":110,"unpackedSize":8378487,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIHXTbefYJCl1g8Zb7PAVCCgIK/f4U1G6aw0ZYoUam6GLAiEAjIzaKehG1iRe+cXzJOFZLiklMjlxei4R+6HYHcDF7HQ="}]},"_npmUser":{"name":"b0rza","email":"apps.npm@aldalo.me"},"directories":{},"maintainers":[{"name":"b0rza","email":"apps.npm@aldalo.me"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/gitcoin-chain-data_1.1.2_1728986117079_0.801763742036574"},"_hasShrinkwrap":false}},"time":{"created":"2024-10-14T08:50:15.207Z","modified":"2024-10-15T09:55:17.522Z","1.0.40":"2024-10-14T08:50:15.506Z","1.1.0":"2024-10-15T08:25:10.399Z","1.1.1":"2024-10-15T08:29:13.668Z","1.1.2":"2024-10-15T09:55:17.338Z"},"bugs":{"url":"https://github.com/b0rza/gitcoin-chain-data/issues"},"author":{"name":"jaxcoder"},"license":"MIT","homepage":"https://github.com/b0rza/gitcoin-chain-data#readme","keywords":["gitcoin","chain","data"],"repository":{"type":"git","url":"git+https://github.com/b0rza/gitcoin-chain-data.git"},"description":"A library for interacting with the Gitcoin chain data.","maintainers":[{"name":"b0rza","email":"apps.npm@aldalo.me"}],"readme":"# Gitcoin Common Data Package\n\nThe Gitcoin Common Data Package sources all the chains and supported tokens used by Gitcoin for:\n- Grants-stack DApps\n- Grants-stack-indexer\n- Any other side-car aiming to leverage the supported chains/tokens\n\n## Installation\n\nTo install the package, use the following command:\n\n```bash\nnpm i \"@gitcoin/gitcoin-chain-data\"\n```\n\n## Functions\n\nThe package exposes the following functions, found in [index.ts](./src/index.ts):\n\n- `getChains()`: Returns `TChain[]`\n- `getChainById(chainId)`: Returns `TChain`\n- `getTokens()`: Returns `TToken[]`\n- `getTokensByChainId(chainId)`: Returns `TToken[]`\n- `getTokenByChainIdAndAddress(chainId, address)`: Returns `TToken`\n\nThe types can be found in [types.ts](./src/types.ts).\n\n## Adding a New Chain\n\nTo add a new chain, follow these steps:\n\n1. Run the following command:\n   ```bash\n   npm run new-chain <CHAIN_ID>\n   ```\n2. A new file will be created at `src/data/chains/<CHAIN_ID>/chain.ts`.\n3. Update `chain.ts` with the specific data for the new chain.\n4. Update `src/chains/chainImportMap.ts` to add the new chain\n\n## Adding a New Token to a Chain\n\nTo add a new token to an existing chain:\n\n1. Open the file at `src/data/chains/<CHAIN_ID>/chain.ts`.\n2. Update the `tokens` array to include the new token information.\n\n## Contributing\n\nTo contribute to the project, follow these steps:\n\n### Install Dependencies\n\nInstall the necessary dependencies with:\n\n```bash\nnpm i\n```\n\n### Build\n\nBuild the project with:\n\n```bash\nnpm run build\n```\n\n### Publish\n\nTo publish the package, use:\n\n```bash\nnpm publish\n```\n\n---\n\nThis version improves readability, structure, and clarity. It provides clear instructions for installation, usage, adding new chains and tokens, and contributing to the project.\n","readmeFilename":"README.md"}