React Native support
See original GitHub issueReact Native’s network stack is pretty compatible with the browser’s so I don’t think it would be much of a stretch to officially support React Native.
I was able to get a minimal example working with a few tweaks:
- Mirage and Pretender both assume
self
is available. Using RN-browser-polyfill to exposeglobal
asself
before importing mirage fixed this. We could guard against this, but the polyfill seems to be a common enough solution for this in RN. - Pretender uses
document.createElement('a')
to parse URLs which isn’t available in mobile. I “fixed” this by patching mirage’s umd’dparseUrl
to fall back tourl-parse
. This should be fixed upstream or we can at least move the patch to mirage itself.
@samselikoff mentioned some de-pretender
ingthat’s happening for node support, so that may also be an option 💯
Issue Analytics
- State:
- Created 4 years ago
- Reactions:6
- Comments:13 (4 by maintainers)
Top Results From Across the Web
Where to get help - React Native
If you need help with your React Native app, the right place to ...
Read more >Where To Get Support - React
Where To Get Support. React has a community of millions of developers. On this page we've listed some React-related communities that you can...
Read more >React Native - Wikipedia
React Native is an open-source UI software framework created by Meta Platforms, Inc. It is used to develop applications for Android, Android TV,...
Read more >React Native Experts to Help, Mentor, Review Code & More
Find a freelance React Native expert for help with reviewing code, mentorship, tutoring, and other React Native help you might need.
Read more >react-native/SUPPORT.md at main - GitHub
I have a question or need help with my React Native app. If you have a coding question related to React Native, it...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
This is all set! ✨
Check out the new quickstart guides here:
Awesome, thanks so much! Getting your instructions into a QuickStart would also be 💯