Issue when used with expo build:web
See original GitHub issueDecision Table
- My issue does not look like “The HTML attribute ‘xxx’ is ignored” (unless we claim support for it)
- My issue does not look like “The HTML element
<yyy>
is not rendered”
Good Faith Declaration
- I have read the HELP document here: https://git.io/JBi6R
- I have read the CONTRIBUTING document here: https://git.io/JJ0Pg
- I have confirmed that this bug has not been reported yet
Description
See console on https://app.gricdeq.org/ for live example till fixed crosses fingers
From the console
Uncaught TypeError: Cannot read properties of undefined (reading ‘call’) at l (bootstrap:79:22) at Module.<anonymous> (index.js:1:1) at l (bootstrap:79:22) at Object.<anonymous> (defaultListStyleSpecs.ts:1:1) at l (bootstrap:79:22) at Object.<anonymous> (SharedPropsProvider.tsx:2:1) at l (bootstrap:79:22) at Object.<anonymous> (RenderHTMLConfigProvider.tsx:4:1) at l (bootstrap:79:22) at Object.<anonymous> (RenderHTML.tsx:5:1)
I confirmed the issue is with react-native-render-html two ways. First, in my actual project I removed the use and the build worked. Second, I create a new expo app, added all the packages I’m currently using, and the build worked until I imported react-native-render-html into App.js
Meanwhile, expo start
and running in browser works fine. Android & IOS builds are fine too. It’s just web builds that seem to have this issue.
React Native Information
info Fetching system and libraries information...
(node:15228) Warning: Accessing non-existent property 'padLevels' of module exports inside circular dependency
(Use `node --trace-warnings ...` to show where the warning was created)
System:
OS: Windows 10 10.0.19044
CPU: (8) x64 Intel(R) Core(TM) i7-8650U CPU @ 1.90GHz
Memory: 4.68 GB / 15.92 GB
Binaries:
Node: 16.14.2 - C:\Program Files\nodejs\node.EXE
Yarn: 1.22.11 - ~\AppData\Roaming\npm\yarn.CMD
npm: 7.19.0 - C:\Program Files\nodejs\npm.CMD
Watchman: Not Found
SDKs:
Android SDK: Not Found
Windows SDK:
AllowAllTrustedApps: Disabled
Versions: 10.0.17763.0
IDEs:
Android Studio: Version 3.5.0.0 AI-191.8026.42.35.6010548
Visual Studio: 16.11.32126.315 (Visual Studio Community 2019)
Languages:
Java: 1.8.0_162
npmPackages:
@react-native-community/cli: Not Found
react: 18.0.0 => 18.0.0
react-native: ^0.69.6 => 0.69.6
react-native-windows: Not Found
npmGlobalPackages:
*react-native*: Not Found
RNRH Version
6.3.4
Tested Platforms
- Android
- iOS
- Web
- MacOS
- Windows
Reproduction Platforms
- Android
- iOS
- Web
- MacOS
- Windows
Minimal, Reproducible Example
npx create-expo-app test-app
npm install react-native-web --force
npm install react-native-render-html
App.js
+ import RenderHTML from 'react-native-render-html';
expo build:web
Test however you go about testing web builds…
Additional Notes
No response
Issue Analytics
- State:
- Created a year ago
- Comments:15
Top GitHub Comments
As a workaround, downgrading
@expo/webpack-config
from0.17.2
to0.16.2
did it for us. Not sure what changed in the config that could cause this problem. Will keep an eye on this!Yes, it is not ideal at all, I would like to have a proper fix too. In my case I just want to display really minimal HTML and the above hack suffice.