
Research
/Security News
Miasma Mini Shai-Hulud Hits ImmobiliareLabs npm Packages
Miasma Mini Shai-Hulud hits @immobiliarelabs Backstage plugins, targeting GitLab and LDAP auth packages on npm.
crypto-icon-cli
Advanced tools
CLI tool để quản lý và thêm các crypto token icon vào dự án React của bạn. Tool này giúp bạn chỉ thêm các icon mà bạn cần, thay vì phải import toàn bộ thư viện icon nặng nề.
# Cài đặt toàn cục
npm install -g crypto-icon-cli
# Hoặc sử dụng trực tiếp với npx
npx crypto-icon-cli <command>
npx crypto-icon-cli init
Lệnh này sẽ tạo cấu trúc thư mục cơ bản cho các crypto icon:
/your-project
/src
/components
/tokens # Chứa các token icon
/wallets # Chứa các wallet icon
/systems # Chứa các system icon
/utils # Utility functions
/types # Type definitions
/constants # Constant values
# Thêm một hoặc nhiều token icon
npx crypto-icon-cli add --token BTC ETH SOL
# Thêm một hoặc nhiều wallet icon
npx crypto-icon-cli add --wallet MetaMask WalletConnect
# Thêm các system icon
npx crypto-icon-cli add --system Blockchain NFT
# Thêm nhiều loại icon cùng lúc
npx crypto-icon-cli add --token BTC ETH --wallet MetaMask
# Chỉ định thư mục đích
npx crypto-icon-cli add --token BTC --dir ./src/assets/crypto
Nếu không chỉ định tùy chọn, tool sẽ hiển thị menu tương tác để bạn chọn.
Khi bạn thêm một token icon, ví dụ như BTC, các file sau sẽ được tạo hoặc cập nhật:
./src/components/tokens/IconBTC.tsx - Component cho BTC icon./src/components/tokens/index.ts - Export cho icon./src/components/types/index.ts - Cập nhật enum TokenName./src/components/constants/imagePaths.ts - URL của imageSau khi đã thêm các icon, bạn có thể sử dụng chúng trong dự án như sau:
import { IconBTC } from "./components/tokens";
function App() {
return (
<div>
<h1>Bitcoin Icon</h1>
<IconBTC />
{/* Với các props của MUI SvgIcon */}
<IconBTC fontSize="large" color="primary" />
</div>
);
}
Đóng góp luôn được chào đón! Vui lòng tạo issue hoặc pull request nếu bạn muốn thêm tính năng hoặc sửa lỗi.
ISC
FAQs
CLI tool for adding crypto token icons to your project
The npm package crypto-icon-cli receives a total of 0 weekly downloads. As such, crypto-icon-cli popularity was classified as not popular.
We found that crypto-icon-cli demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Research
/Security News
Miasma Mini Shai-Hulud hits @immobiliarelabs Backstage plugins, targeting GitLab and LDAP auth packages on npm.

Security News
Rolldown paused Rust React Compiler integration after a 5MB binary size increase raised concerns about shipping React-specific code to all Vite users.

Security News
/Research
Mini Shai-Hulud expands into the Go ecosystem after hitting LeoPlatform npm packages and targeting GitHub Actions workflows.