[deprecated in favor of https://microsoft.github.io/react-native-windows/] React Native for macOS is an experimental fork for writing desktop apps using Cocoa
MIT License
11.24k
stars
429
forks
source link
Add module resolve `react-native` to `react-native-macos` #125
Add module resolve react-native to react-native-macos by babel-plugin-module-resolver. As a result, we can ensure that don't require('react-native') in the packager of react-native-macos.
It work with following code:
import React from 'react';
import {
AppRegistry,
StyleSheet,
Text,
View,
} from 'react-native';
import FoldView from 'react-native-foldview';
Sorry for a slow reply, need some time to consider all pros and cons on this and test it out more. I understand the problem, and have it also, so it looks legimate and good solution.
Add module resolve
react-native
toreact-native-macos
by babel-plugin-module-resolver. As a result, we can ensure that don'trequire('react-native')
in the packager ofreact-native-macos
.It work with following code: