1
0
mirror of https://github.com/oceanprotocol/commons.git synced 2023-03-15 18:03:00 +01:00

add isWeb3Capable

This commit is contained in:
Jernej Pregelj 2019-07-11 14:04:40 +02:00
parent 25ab6e0c42
commit b4db8a6556
2 changed files with 3 additions and 0 deletions

View File

@ -49,6 +49,7 @@ declare global {
interface UserProviderState {
isLogged: boolean
isBurner: boolean
isWeb3Capable: boolean
isLoading: boolean
isOceanNetwork: boolean
account: string
@ -107,6 +108,7 @@ export default class UserProvider extends PureComponent<{}, UserProviderState> {
public state = {
isLogged: false,
isBurner: false,
isWeb3Capable: Boolean(window.web3 || window.ethereum),
isLoading: true,
isOceanNetwork: false,
balance: {

View File

@ -3,6 +3,7 @@ import React from 'react'
export const User = React.createContext({
isLogged: false,
isBurner: false,
isWeb3Capable: false,
isLoading: false,
isOceanNetwork: false,
account: '',