/create-react-native-dapp

Your next Ethereum application starts here. ⚛️ 💪 🦄

Primary LanguageTypeScriptMIT LicenseMIT

npx create-react-native-dapp

https://img.shields.io/badge/strictly-typescript-blue https://img.shields.io/badge/platforms-android%2Cios%2Cweb-brightgreen https://img.shields.io/badge/powered--by-hardhat-orange https://img.shields.io/badge/chat-on%20discord-red

create-react-native-dapp is an npx utility to help quickly bootstrap React Native ⚛️ applications with access to the Ethereum Blockchain.

Our goal is to help create a sustainable open source ecosystem for Web3 in React Native by providing a dependable common runtime which we can buidl upon and extend together.

🔥 Features

  • 🚀 Bootstrapped by Expo.
    • Easily take advantage of Expo's high quality, well-supported and well-documented library architecture.
    • Supports Android, iOS and the Web.
  • 👷 Served with Hardhat.
    • Your generated app comes with a simple example contract which you can deploy, test and interact with directly.
  • 👛 Powered by WalletConnect.
    • Connect to secure wallets such as Rainbow 🌈 out of the box!
  • 🏗️ It's typed, and pretty.
    • It comes pre-configured with TypeScript to help write applications that scale.
    • It's integrated with prettier and husky to ensure coding standards are enforced right from the beginning.
  • 😉 And it's ready to go.
    • Built applications come pre-packaged with .env support using react-native-dotenv and companion tests for your contracts.
    • Projects are initialized using deep linking so external navigation is a breeze.

To get started,

First, please make sure you've logged into expo-cli.

npx create-react-native-dapp

This will walk you through the creation of your Ethereum-enabled application, which works on Android, iOS and the Web.

To start the app, you can:

cd my-react-dapp
yarn ios # android, web

To programmatically invoke,

create-react-native-dapp also exports a simple interface for the programmatic allocation of new projects.

import { create } from 'create-react-native-dapp';

(async () => {
  const name = 'my-react-dapp';
  const bundleIdentifier = 'io.github.cawfree.dapp';
  const uriScheme = 'myapp'; // navigate using myapp://some/path
  const { dir } = await create({
    name,
    bundleIdentifer,
    packageName: bundleIdentifier,
    uriScheme,
  });
})();

✌️ License

MIT