Convert Figma logo to code with AI

MetaCubeX logometacubexd

Mihomo Dashboard, The Official One, XD

1,436
234
1,436
24

Top Related Projects

4,027

Yet Another Clash Dashboard

A Clash GUI based on tauri. Supports Windows, macOS and Linux.

Run sing-box/mihomo as client in shell

Quick Overview

MetaCubeX/metacubexd is a decentralized application (dApp) that allows users to create and trade non-fungible tokens (NFTs) on the Ethereum blockchain. The project aims to provide a user-friendly platform for artists, creators, and collectors to engage with the growing NFT ecosystem.

Pros

  • Decentralized: The project is built on the Ethereum blockchain, ensuring a decentralized and transparent platform for NFT creation and trading.
  • User-friendly: The project aims to provide a simple and intuitive interface for users to create, buy, and sell NFTs.
  • Diverse NFT Offerings: The platform supports a wide range of NFT types, including digital art, collectibles, and in-game assets.
  • Community-driven: The project has an active community of developers and users who contribute to its growth and development.

Cons

  • Ethereum Gas Fees: As the project is built on the Ethereum blockchain, users may be subject to high gas fees for transactions, which can be a barrier to entry for some.
  • Scalability Concerns: The Ethereum network has faced scalability issues in the past, which could potentially impact the performance and user experience of the MetaCubeX platform.
  • Regulatory Uncertainty: The NFT and cryptocurrency space is still subject to evolving regulatory frameworks, which could introduce uncertainty and risk for the project.
  • Potential for Fraud: As with any decentralized platform, there is a risk of fraud and scams, which the project must work to mitigate.

Code Examples

// Example of an NFT contract in Solidity
pragma solidity ^0.8.0;

import "@openzeppelin/contracts/token/ERC721/ERC721.sol";
import "@openzeppelin/contracts/utils/Counters.sol";

contract MetaCubeNFT is ERC721 {
    using Counters for Counters.Counter;
    Counters.Counter private _tokenIdCounter;

    constructor() ERC721("MetaCubeNFT", "MCNFT") {}

    function safeMint(address to) public {
        uint256 tokenId = _tokenIdCounter.current();
        _tokenIdCounter.increment();
        _safeMint(to, tokenId);
    }
}

This code example demonstrates a basic NFT contract in Solidity, using the OpenZeppelin library for the ERC721 standard. The contract allows users to mint new NFTs and tracks the token IDs using a counter.

// Example of a React component for minting an NFT
import { useState } from 'react';
import { ethers } from 'ethers';
import MetaCubeNFTContract from './MetaCubeNFTContract';

const MintNFT = () => {
  const [loading, setLoading] = useState(false);

  const handleMint = async () => {
    setLoading(true);
    try {
      const provider = new ethers.providers.Web3Provider(window.ethereum);
      const signer = provider.getSigner();
      const contract = new ethers.Contract(
        MetaCubeNFTContract.address,
        MetaCubeNFTContract.abi,
        signer
      );
      await contract.safeMint(await signer.getAddress());
      console.log('NFT minted successfully!');
    } catch (error) {
      console.error('Error minting NFT:', error);
    } finally {
      setLoading(false);
    }
  };

  return (
    <div>
      <button onClick={handleMint} disabled={loading}>
        {loading ? 'Minting...' : 'Mint NFT'}
      </button>
    </div>
  );
};

export default MintNFT;

This React component provides a simple interface for minting an NFT on the MetaCubeX platform. It uses the ethers.js library to interact with the NFT contract and the user's Ethereum wallet.

Getting Started

To get started with the MetaCubeX project, follow these steps:

  1. Install the required dependencies:
    npm install
    

2

Competitor Comparisons

4,027

Yet Another Clash Dashboard

Pros of yacd

  • Lightweight and fast-loading interface
  • Supports multiple languages and themes
  • Well-established project with a longer history

Cons of yacd

  • Less frequent updates compared to metacubexd
  • Fewer advanced features for power users
  • Limited customization options for the dashboard layout

Code Comparison

metacubexd:

import { defineConfig } from 'vite'
import react from '@vitejs/plugin-react'
import { VitePWA } from 'vite-plugin-pwa'

export default defineConfig({
  plugins: [react(), VitePWA()],
})

yacd:

const HtmlWebpackPlugin = require('html-webpack-plugin');
const MiniCssExtractPlugin = require('mini-css-extract-plugin');

module.exports = {
  plugins: [new HtmlWebpackPlugin(), new MiniCssExtractPlugin()],
};

Summary

Both metacubexd and yacd are web dashboards for Clash, but they differ in their approach and features. yacd offers a lightweight and multilingual interface with a longer project history, while metacubexd provides more frequent updates and advanced features for power users. The code comparison shows that metacubexd uses Vite with React and PWA support, while yacd relies on webpack for its build process.

A Clash GUI based on tauri. Supports Windows, macOS and Linux.

Pros of clash-verge

  • More mature project with a larger user base and community support
  • Offers a wider range of features and customization options
  • Supports multiple platforms including Windows, macOS, and Linux

Cons of clash-verge

  • May have a steeper learning curve for new users due to its extensive features
  • Potentially higher resource usage compared to metacubexd
  • Less frequent updates and slower bug fixes in recent months

Code Comparison

metacubexd:

import { defineConfig } from 'vite'
import react from '@vitejs/plugin-react'
import { VitePWA } from 'vite-plugin-pwa'

export default defineConfig({
  plugins: [react(), VitePWA()],
})

clash-verge:

import { defineConfig } from "vite";
import react from "@vitejs/plugin-react";
import { VitePWA } from "vite-plugin-pwa";

export default defineConfig({
  plugins: [react(), VitePWA()],
});

Both projects use similar build configurations with Vite, React, and PWA support. The main difference is that clash-verge uses TypeScript, while metacubexd uses JavaScript.

Run sing-box/mihomo as client in shell

Pros of ShellCrash

  • Lightweight and efficient, suitable for resource-constrained devices
  • Extensive shell script support for customization and automation
  • Cross-platform compatibility, including various Linux distributions and routers

Cons of ShellCrash

  • Less user-friendly interface compared to metacubexd's web-based dashboard
  • Limited built-in visualization tools for network traffic analysis
  • Steeper learning curve for users unfamiliar with command-line interfaces

Code Comparison

ShellCrash (shell script):

#!/bin/sh
# ShellCrash installation script
check_sys(){
    if [ -f /etc/redhat-release ]; then
        release="centos"
    elif cat /etc/issue | grep -q -E -i "debian"; then
        release="debian"
    fi
}

metacubexd (JavaScript):

// metacubexd configuration
const config = {
  theme: 'dark',
  language: 'en',
  apiBaseUrl: '/api',
  updateInterval: 3000,
};

The code snippets highlight the different approaches: ShellCrash focuses on shell scripting for system detection and configuration, while metacubexd utilizes JavaScript for web-based interface configuration.

Convert Figma logo designs to code with AI

Visual Copilot

Introducing Visual Copilot: A new AI model to turn Figma designs to high quality code using your components.

Try Visual Copilot

README

metacubexd

Mihomo Dashboard, The Official One, XD

preview-overview

pr-closed last-commit build downloads license

Preview

preview-overview preview-connections

Published Official Links

GH Pages: https://metacubex.github.io/metacubexd

Cloudflare Pages: https://metacubexd.pages.dev

Usage

Enable external-controller in your config file

external-controller: 0.0.0.0:9090

Use pre-built assets from gh-pages branch

First time setup

git clone https://github.com/metacubex/metacubexd.git -b gh-pages /etc/mihomo/ui

Make sure you have external-ui directory set correctly in your config file

external-ui: /etc/mihomo/ui

Update

git -C /etc/mihomo/ui pull -r

Run inside Docker

docker cli

Running

docker run -d --restart always -p 80:80 --name metacubexd ghcr.io/metacubex/metacubexd

Update and Restart

docker pull ghcr.io/metacubex/metacubexd && docker restart metacubexd

docker-compose.yml

version: '3'

services:
  metacubexd:
    container_name: metacubexd
    image: ghcr.io/metacubex/metacubexd
    restart: always
    ports:
      - '80:80'

  # optional
  meta:
    container_name: meta
    image: docker.io/metacubex/mihomo:Alpha
    restart: always
    pid: host
    ipc: host
    network_mode: host
    cap_add:
      - ALL
    volumes:
      - ./config.yaml:/root/.config/mihomo
      - /dev/net/tun:/dev/net/tun

Running

docker compose up -d

Update and Restart

docker compose pull && docker compose up -d

Build locally

Install npm dependencies

pnpm install

Build artifacts

pnpm build

Serve static files

pnpm serve

Credits