Expo client not working after integration of web platform

I’ve been working on an expo project for a while. I’ve recently learned that we can develop a website with expo as well.

Once I started adding the web portion of the application, I experienced issues with expo when run on my physical device and the simulator.

Some of the issues I experienced were:

  1. Expo client not reloading after code change in my IDE
  2. Network requests are not sent
  3. Console.logs are not shown in my terminal

When I run the project as a website, none of these problems occur.

Here is my app.json

{
  "expo": {
    "name": "client-app",
    "slug": "client-app",
    "version": "1.0.0",
    "orientation": "portrait",
    "icon": "./src/assets/icon.png",
    "splash": {
      "image": "./src/assets/splash.png",
      "resizeMode": "contain",
      "backgroundColor": "#ffffff"
    },
    "updates": {
      "fallbackToCacheTimeout": 0
    },
    "assetBundlePatterns": [
      "**/*"
    ],
    "ios": {
      "supportsTablet": true
    },
    "web": {
      "favicon": "./src/assets/favicon.png"
    },
    "platforms": [
      "android",
      "ios",
      "web"
    ]
  }
}

As you can see I have added all three platforms.

if I run expo diagnostics this is the result.

  Expo CLI 3.28.0 environment info:
    System:
      OS: macOS 10.15.7
      Shell: 5.7.1 - /bin/zsh
    Binaries:
      Node: 12.19.0 - /usr/local/bin/node
      Yarn: 1.22.5 - /usr/local/bin/yarn
      npm: 6.14.8 - /usr/local/bin/npm
      Watchman: 4.9.0 - /usr/local/bin/watchman
    Managers:
      CocoaPods: 1.9.3 - /usr/local/bin/pod
    SDKs:
      iOS SDK:
        Platforms: iOS 14.0, DriverKit 19.0, macOS 10.15, tvOS 14.0, watchOS 7.0
    IDEs:
      Android Studio: 3.4 AI-183.5429.30.34.5452501
      Xcode: 12.0.1/12A7300 - /usr/bin/xcodebuild
    npmPackages:
      expo: ~39.0.2 => 39.0.3
      react: 16.13.1 => 16.13.1
      react-dom: ^16.13.1 => 16.13.1
      react-native: https://github.com/expo/react-native/archive/sdk-39.0.3.tar.gz => 0.63.2
      react-native-web: ^0.11.7 => 0.11.7
    npmGlobalPackages:
      expo-cli: 3.28.0
    Expo Workflow: managed

I tried

rm -rf node_modules
rm package-lock.json
watchman watch-del-all
npm cache clean --force
npm install

still not working.

I also created a new project with expo init and these problems do not occur so it could be my configuration of all platforms (ios, android, web) that could be incorrect.

Does anyone know how to fix these problems?

Hey @malusi, can you detail the exact changes you made to your project when you integrated web support?

Cheers,
Adam

Hey @adamjnav, thanks for taking the time to reply, I was able to pinpoint the bug in my code. It has nothing to do with my web configuration or expo, so I don’t think I should share it.