Getting web (and webpack) working with previous Expo project

Trying to follow this guide

I’m on expo 36.

We’ve been on expo for a long time, a few years, and we don’t even have a AppRegistry line in our app nor a index.js in our app. Here is the upgrade instructions for getting to expo web -

React Native-Only : Update your root index.js

  import {
+      Platform
  } from 'react-native';
  import App from './App';
  import {name as appName} from './app.json';

  AppRegistry.registerComponent(appName, () => App);

+  if (Platform.OS === 'web') {
+      AppRegistry.runApplication(appName, {
+          rootTag: document.getElementById('root'),
+      });
+  }

So I’ve added an index.js which has all of the elements here, I’ve added the following to App.json:

     "entryPoint": "node_modules/expo/AppEntry.js",
    "platforms": [

in package.json we’ve already got:

  "main": "./node_modules/expo/AppEntry.js",

I had to put a flag on Mobile only features, then I needed to override the default webpack loader with a typescript loader, the error I’m getting on expo start --web seems to be a react-native error:

 web  Failed to compile.
Module not found: Can't resolve '../Components/AccessibilityInfo/AccessibilityInfo' in '/home/user/WebstormProjects/myApp/customer/node_modules/react-native/Libraries/react-native'
✖ 「wdm」: Hash: c932c15ca702129a5e96
Version: webpack 4.39.0
Time: 668ms
Built at: 12/11/2019 5:56:10 PM
  Asset      Size  Chunks  Chunk Names
main.js  41.8 KiB       0  main
Entrypoint main = main.js
 [0] ./node_modules/react-native/Libraries/react-native/react-native-implementation.js 15.3 KiB {0} [built]
 [1] ./app.json 1.36 KiB {0} [built]
 [2] ./node_modules/react-native/Libraries/Renderer/shims/ReactNative.js 334 bytes {0} [built] [failed] [1 error]
 [3] ./node_modules/react-native/Libraries/EventEmitter/RCTDeviceEventEmitter.js 464 bytes {0} [built] [failed] [1 error]
 [5] ./App.js 444 bytes {0} [built] [failed] [1 error]
 [6] ./index.js 296 bytes {0} [built]
 [7] ./node_modules/invariant/browser.js 1.36 KiB {0} [built]
 [8] ./node_modules/react-native/Libraries/Utilities/warnOnce.js 339 bytes {0} [built] [failed] [1 error]
 [9] ./node_modules/react-native/Libraries/Components/ActivityIndicator/ActivityIndicator.js 409 bytes {0} [built] [failed] [1 error]
[10] ./node_modules/react-native/Libraries/ART/ReactNativeART.js 355 bytes {0} [built] [failed] [1 error]
[11] ./node_modules/react-native/Libraries/Components/Button.js 375 bytes {0} [built] [failed] [1 error]
[12] ./node_modules/react-native/Libraries/Lists/FlatList.js 381 bytes {0} [built] [failed] [1 error]
[13] ./node_modules/react-native/Libraries/Image/ImageBackground.js 378 bytes {0} [built] [failed] [1 error]
[14] ./node_modules/react-native/Libraries/Components/TextInput/InputAccessoryView.js 405 bytes {0} [built] [failed] [1 error]
[15] ./node_modules/react-native/Libraries/Components/Keyboard/KeyboardAvoidingView.js 442 bytes {0} [built] [failed] [1 error]
    + 63 hidden modules

WARNING in ./index.js 5:30-37
"export 'name' (imported as 'appName') was not found in './app.json'

WARNING in ./index.js 8:29-36
"export 'name' (imported as 'appName') was not found in './app.json'

WARNING in configuration
The 'mode' option has not been set, webpack will fallback to 'production' for this value. Set 'mode' option to 'development' or 'production' to enable defaults for each environment.

I’m kind of at a loss as to what to do next. Any suggestions?

What I would try is create a new bare typescript app using expo init. Then compare the newly generated files (app.json, package.json, App.tsx, babel.config.js, tsconfig.json) with the corresponding files in your app.

If you need a customized webpack config then also run expo customize:web in the blank project.