npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

solidity-registry

v1.0.0

Published

Solidity registry

Readme

solidity-registry

목적

재사용 가능한 Solidity 컨트랙트 모듈(contracts/standard/** 등)과, 이를 기반으로 한 구현체/프리셋, 테스트를 한 저장소에서 관리합니다.

디렉토리

  • contracts/standard/: 라이브러리(베이스/믹스인/민터/공용 에러)
  • contracts/implementations/: standard 모듈을 조합한 배포 가능한 구현체/프리셋
    • contracts/implementations/standard/StandardPresetMinimal.sol: 최소 프리셋
    • contracts/implementations/standard/StandardPresetFull.sol: 풀 프리셋(여러 믹스인 조합)
    • contracts/implementations/chainlink/ChainlinkPresetMinimal.sol: RevealMinter 호환 최소 프리셋
  • contracts/mocks/: Hardhat 테스트용 목업
  • test/: Hardhat 테스트

개발/테스트

의존성 설치:

npm install

테스트:

npm test

배포용 lib (implementations)

contracts/implementations/** 프리셋을 직접 배포할 수 있도록, 컨트랙트 bytecode + constructor args를 합쳐 txData를 만들고, 서명 가능한 EIP-1559 Deploy 트랜잭션을 구성하는 헬퍼를 제공합니다.

  • src/lib/deploy/implementations.ts: 프리셋 deploy 트랜잭션 생성
  • src/lib/transaction/transaction.ts: makeTx, makeDeployTx

예시(외부 RPC에서 deploy tx 만들기):

import { Wallet, ethers } from 'ethers';
import { makeImplementationDeployTx } from '@modernlion/solidity-registry';

const rpcUrl = process.env.RPC_URL!;
const pk = process.env.PRIVATE_KEY!;

const provider = new ethers.providers.JsonRpcProvider(rpcUrl);
const signer = new Wallet(pk, provider);

const tx = await makeImplementationDeployTx(
  'StandardPresetMinimal',
  ['MyNFT', 'MNFT', 1000, 'https://example.com/metadata/'],
  provider,
  await signer.getAddress(),
);

const signed = await signer.signTransaction(tx);
const receipt = await (await provider.sendTransaction(signed)).wait();
console.log('deployed at', receipt.contractAddress);

배포 (npm) — GitHub Actions

npm 배포는 수동 publish 대신 GitHub Actions로만 수행하는 것을 권장합니다.

  1. Secrets 설정
    Repository → Settings → Secrets and variables → Actions 에서 NPM_TOKEN 추가

    • npm.com 로그인 → 프로필 클릭 → Access TokensGenerate New TokenGranular Access token 선택
    • 권한: Read and write (패키지 배포용), 적용할 패키지(또는 전체) 지정
    • Bypass 2FA for publish (또는 "2FA 우회") 옵션을 켜기 — CI에서는 OTP를 입력할 수 없으므로, 이 옵션이 없으면 publish 시 EOTP 에러가 납니다.
    • 생성된 토큰(npm_...)을 복사해 GitHub Secret에 붙여넣기
  2. 배포 절차

    • 배포할 버전으로 태그를 푸시하면 자동으로 npm publish 됨. (테스트는 CI에서만 수행, publish 워크플로에서는 중복 제거)
    • 예: git tag v1.0.1 && git push origin v1.0.1
    • 제약: 태그는 main 또는 master 브랜치에 있는 커밋에만 붙여야 함. 그렇지 않으면 배포 단계에서 실패함. (main에 푸시 → CI 통과 후 태그 푸시 권장)
    • 워크플로: .github/workflows/publish.yml (태그 v* 푸시 시 실행)
  3. CI

참고(Chainlink + OZ import)

@chainlink/contracts@openzeppelin/[email protected]/... 형태로 import하는 파일이 있어, npm installscripts/postinstall.cjsnode_modules/@openzeppelin/[email protected] 별칭을 자동 생성합니다.