-
-
Notifications
You must be signed in to change notification settings - Fork 26.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Better React Native Web support #2511
Merged
gaearon
merged 2 commits into
facebook:master
from
mini-eggs:better-react-native-support
Jun 28, 2017
Merged
Better React Native Web support #2511
gaearon
merged 2 commits into
facebook:master
from
mini-eggs:better-react-native-support
Jun 28, 2017
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Did you verify if this works with Jest? I'm not sure how to do it there, but at least checking would be great! |
Seems fine to me. Thanks! |
Merged
Fixed in 1.0.8. Please verify. |
Working great! Glad this is in master. Can finally delete my fork. 👍 Tested with |
zangrafx
added a commit
to absolvent/create-react-app
that referenced
this pull request
Jun 29, 2017
* upstream/master: (55 commits) Fix minor typo (facebook#2679) Bootstrap with Yarn when available (facebook#2673) Add more info about apache client side routing (facebook#2666) Test Node 8 on Travis (facebook#2659) Add json and css to lint-staged in template README (facebook#2671) Add a note about fixed vulnerability in 1.0.8 Publish Changelog for 1.0.8 (facebook#2664) Reformat source code with Prettier 1.5.2 Update Prettier to v1 (facebook#2465) Update ISSUE_TEMPLATE.md Local testing docker links (facebook#2662) Better React Native Web support (facebook#2511) Bump dependencies (facebook#2658) Minor code style edits to user guide (facebook#2660) Don't ask to install webpack for using Styleguidist (facebook#2656) Put react-scripts in dependencies, not devDependencies (facebook#2657) Razzle added to the alternatives (facebook#2517) Warn about large bundle sizes (facebook#2648) Add instructions to use source-map-explorer (facebook#1641) ... # Conflicts: # packages/react-dev-utils/package.json # packages/react-scripts/config/webpack.config.dev.js # packages/react-scripts/config/webpack.config.prod.js # packages/react-scripts/package.json
romaindso
pushed a commit
to romaindso/create-react-app
that referenced
this pull request
Jul 10, 2017
* Better React Native Web support * Adding better react-native-web support for jest testing
wmonk
referenced
this pull request
in wmonk/create-react-app-typescript
Aug 7, 2017
* Better React Native Web support * Adding better react-native-web support for jest testing
morgs32
pushed a commit
to BrickworkSoftware/create-react-app
that referenced
this pull request
Sep 1, 2017
* Better React Native Web support * Adding better react-native-web support for jest testing
Merged
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR will be fixing a pain point I've been experiencing in code reuse of React Native projects with Create React App projects. The React Native bundler will allow Android specific code to resolve with a prefixed
.android
on the default.js
/.jsx
extension. This PR is allowing that same functionality but with web specific code.While React Native Web support has been added in in the past, the addition did not follow
https://github.com/necolas/react-native-web/blob/master/docs/guides/getting-started.md exactly, missing the added extensions options to the webpack config.
Something I may have missed in the PR is making any additional changes to the file
/create-react-app/packages/react-scripts/scripts/utils/createJestConfig.js
. Will there need to be any additional extension resolving here? I'm not too familiar with Jest setups but would be happy to add anything in if I could be pointed in the right direction.Thanks for looking this PR over, lemme know if there's any problems with the changes here. Excited to contribute. 😄