Skip to content

Commit 623e1bd

Browse files
grigiogaearon
authored andcommitted
Add React Native Web support (#407)
1 parent 8ae36c6 commit 623e1bd

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

config/webpack.config.dev.js

+2-1
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,8 @@ module.exports = {
7676
// if we don't have a good solution, we should just make `babel-runtime`
7777
// a dependency in generated projects.
7878
// See https://github.com/facebookincubator/create-react-app/issues/255
79-
'babel-runtime/regenerator': require.resolve('babel-runtime/regenerator')
79+
'babel-runtime/regenerator': require.resolve('babel-runtime/regenerator'),
80+
'react-native': 'react-native-web'
8081
}
8182
},
8283
// Resolve loaders (webpack plugins for CSS, images, transpilation) from the

config/webpack.config.prod.js

+2-1
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,8 @@ module.exports = {
7171
// if we don't have a good solution, we should just make `babel-runtime`
7272
// a dependency in generated projects.
7373
// See https://github.com/facebookincubator/create-react-app/issues/255
74-
'babel-runtime/regenerator': require.resolve('babel-runtime/regenerator')
74+
'babel-runtime/regenerator': require.resolve('babel-runtime/regenerator'),
75+
'react-native': 'react-native-web'
7576
}
7677
},
7778
// Resolve loaders (webpack plugins for CSS, images, transpilation) from the

0 commit comments

Comments
 (0)