Skip to content

Commit

Permalink
refactor ci, add wormhole connect build and portal bridge container
Browse files Browse the repository at this point in the history
  • Loading branch information
Sebastian Scatularo committed Oct 11, 2023
1 parent 9536d3d commit 28c150d
Show file tree
Hide file tree
Showing 322 changed files with 2,948 additions and 139,434 deletions.
12 changes: 0 additions & 12 deletions Dockerfile

This file was deleted.

59 changes: 18 additions & 41 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,50 +1,27 @@
# Example Token Bridge UI
# React + TypeScript + Vite

## Prerequisites
This template provides a minimal setup to get React working in Vite with HMR and some ESLint rules.

- NodeJS v14+
- NPM v7.18+
Currently, two official plugins are available:

## Install
- [@vitejs/plugin-react](https://github.com/vitejs/vite-plugin-react/blob/main/packages/plugin-react/README.md) uses [Babel](https://babeljs.io/) for Fast Refresh
- [@vitejs/plugin-react-swc](https://github.com/vitejs/vite-plugin-react-swc) uses [SWC](https://swc.rs/) for Fast Refresh

```bash
npm ci
```

## Develop

```bash
npm start
```
## Expanding the ESLint configuration

## Build for local tilt network
If you are developing a production application, we recommend updating the configuration to enable type aware lint rules:

```bash
npm run build
```

## Build for testnet
- Configure the top-level `parserOptions` property like this:

```bash
REACT_APP_CLUSTER=testnet npm run build
```js
parserOptions: {
ecmaVersion: 'latest',
sourceType: 'module',
project: ['./tsconfig.json', './tsconfig.node.json'],
tsconfigRootDir: __dirname,
},
```

## Build for mainnet

```bash
REACT_APP_CLUSTER=mainnet REACT_APP_COVALENT_API_KEY=YOUR_API_KEY REACT_APP_SOLANA_API_URL=YOUR_CUSTOM_RPC npm run build
```

## Test Server

```bash
npx serve -s build
```

## Environment Variables (optional)

Create `.env` from the sample file, then add your Covalent API key:

```bash
cp .env.sample .env
```
- Replace `plugin:@typescript-eslint/recommended` to `plugin:@typescript-eslint/recommended-type-checked` or `plugin:@typescript-eslint/strict-type-checked`
- Optionally add `plugin:@typescript-eslint/stylistic-type-checked`
- Install [eslint-plugin-react](https://github.com/jsx-eslint/eslint-plugin-react) and add `plugin:react/recommended` & `plugin:react/jsx-runtime` to the `extends` list
105 changes: 0 additions & 105 deletions config-overrides.js

This file was deleted.

38 changes: 38 additions & 0 deletions index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8" />
<link rel="icon" href="favicon.ico" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
<meta name="theme-color" content="#000000" />
<meta
name="description"
content="Portal is a bridge that offers unlimited transfers across chains for tokens and NFTs wrapped by Wormhole."
/>
<meta property="og:title" content="Portal Token Bridge" />
<meta property="og:type" content="website" />
<meta property="og:url" content="https://portalbridge.com" />
<meta property="og:image" content="wormhole.png" />
<meta property="og:image:alt" content="Wormhole logo" />
<meta
property="og:description"
content="Portal is a bridge that offers unlimited transfers across chains for tokens and NFTs wrapped by Wormhole."
/>
<meta name="twitter:site" content="@portalbridge_" />
<meta name="twitter:creator" content="@portalbridge_" />
<meta name="twitter:card" content="summary_large_image" />
<link rel="apple-touch-icon" href="logo192.png" />
<link rel="manifest" href="manifest.json" />
<link rel="preconnect" href="https://fonts.googleapis.com" />
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin />
<link
href="https://fonts.googleapis.com/css2?family=Poppins:wght@200;300;400;500;600;700&display=swap"
rel="stylesheet"
/>
<title>Portal Token Bridge</title>
</head>
<body>
<div id="root"></div>
<script type="module" src="/src/main.tsx"></script>
</body>
</html>
Loading

0 comments on commit 28c150d

Please sign in to comment.