PHPFixing
  • Privacy Policy
  • TOS
  • Ask Question
  • Contact Us
  • Home
  • PHP
  • Programming
  • SQL Injection
  • Web3.0

Wednesday, July 13, 2022

[FIXED] Why does my react app show up fine on some decvices but on newer ones it only displays a white page

 July 13, 2022     deployment, react-native, reactjs, web-deployment     No comments   

Issue

My app displays fine on older Macs but not on iPhones or new Mac models. What could be the cause of this? I've been trolling web pages for hours and found nothing that makes any sense to me. Please can anyone help!

here is my app.js

import logo from './logo.svg';
import './App.css';
import MetaMaskModal from './components/MetaMaskModal'
import Home from './components/Home'


function App() {
  let provider = window.web3 && window.web3.currentProvider.isMetaMask;
  return (
    <>
      {window.web3 === undefined ? (
        <MetaMaskModal />
      ) : (<Home />)
      }
    </>
  );
}

export default App;

here is my index.js

import React from 'react';
import ReactDOM from 'react-dom';
import './index.css';
import App from './App';
import reportWebVitals from './reportWebVitals';

ReactDOM.render(
  <React.StrictMode>
    <App />
  </React.StrictMode>,
  document.getElementById('root')
);



// If you want to start measuring performance in your app, pass a function
// to log results (for example: reportWebVitals(console.log))
// or send to an analytics endpoint. 
reportWebVitals();

package.json

"homepage": "http://www.mywebsite.com/#home",


Solution

The problem was not for newer machines or devices. It was not showing up on any devices that didn't have metamask already installed.



Answered By - Slimtradeywestcoast
Answer Checked By - Pedro (PHPFixing Volunteer)
  • Share This:  
  •  Facebook
  •  Twitter
  •  Stumble
  •  Digg
Newer Post Older Post Home

0 Comments:

Post a Comment

Note: Only a member of this blog may post a comment.

Total Pageviews

Featured Post

Why Learn PHP Programming

Why Learn PHP Programming A widely-used open source scripting language PHP is one of the most popular programming languages in the world. It...

Subscribe To

Posts
Atom
Posts
Comments
Atom
Comments

Copyright © PHPFixing