set REACT_APP_PROD_ADDRESS for sockets (#12)

* fix: search bar fix if number input, add badge (#2)

* fix: search bar fix if number input, add badge
for type in search bar, horfix for direct link in inventory page

* fix: theme mode blink page

* fix: write boolean in tx page

* fix: styles for contract tab in address page

* fix: remove btn

* fix: env, results per page go to first page
in grid. fix path for REACT_APP_EXPLORER_V1_API_URL

* Update .env.example

* fix: improve

* fix: stable .env

* fix: improve tx

* fix: no update grid if tab not changed

* fix: revert .env file

* fix: add .env.development to gitignore

* env var description

* Update .env

* fix: set to REACT_APP_PROD_ADDRESS socket

Co-authored-by: potvik <57394565+potvik@users.noreply.github.com>
Co-authored-by: Hype <hypnagonia@gmail.com>
pull/19/head
vpcodebase 3 years ago committed by GitHub
parent f625c1a3b8
commit 427d7f5a79
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 6
      .env.example
  2. 1
      .gitignore
  3. 2
      src/api/explorer/ws/index.ts

@ -1,9 +1,15 @@
# rpc for quering shard balances
REACT_APP_RPC_URL_SHARD0=https://a.api.s0.t.hmny.io/
REACT_APP_RPC_URL_SHARD1=https://api.s1.t.hmny.io/
REACT_APP_RPC_URL_SHARD2=https://api.s2.t.hmny.io/
REACT_APP_RPC_URL_SHARD3=https://api.s3.t.hmny.io/
# supported shards, comma separated 0,1,2,3
REACT_APP_AVAILABLE_SHARDS=0,1,2,3
# explorer v1 api for contract verification. (will migrate to v1 in the future)
REACT_APP_EXPLORER_V1_API_URL=https://explorer.pops.one:8888/
# IPFS gateway for tokens assets
REACT_APP_INDEXER_IPFS_GATEWAY=https://ipfs.io/ipfs/
# backend websocket API url
REACT_APP_PROD_ADDRESS=https://explorer-v2-api.hmny.io/
# dev url
REACT_APP_DEV_ADDRESS=https://ws.explorer-v2.hmny.io/

1
.gitignore vendored

@ -20,6 +20,7 @@
# misc
.DS_Store
.env.local
.env.development
.env.development.local
.env.test.local
.env.production.local

@ -1,6 +1,6 @@
import { io } from "socket.io-client";
const socket = io(process.env.REACT_APP_DEV_ADDRESS as string, {
const socket = io(process.env.REACT_APP_PROD_ADDRESS as string, {
transports: ["websocket"],
});

Loading…
Cancel
Save