Skip to content

Commit

Permalink
Move react-native-implementation.js to index.js
Browse files Browse the repository at this point in the history
Summary: I am unsure whether there was a reason not to use an `index.js` file from the beginning. It always struck me as confusing and odd to have the main API hidden in a folder somewhere. This changes RN to use the standard `index.js` file that is common in almost all JavaScript packages.

Reviewed By: yungsters, rubennorte

Differential Revision: D17314423

fbshipit-source-id: 10eaf4fddd41e91163de7d10c0879b623dab00d7
  • Loading branch information
cpojer authored and facebook-github-bot committed Sep 12, 2019
1 parent 607e258 commit e54ecf9
Show file tree
Hide file tree
Showing 6 changed files with 205 additions and 205 deletions.
4 changes: 2 additions & 2 deletions .flowconfig
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
[include]

[libs]
Libraries/react-native/react-native-interface.js
interface.js
flow/

[options]
Expand All @@ -39,7 +39,7 @@ module.file_ext=.ios.js

munge_underscores=true

module.name_mapper='^react-native$' -> '<PROJECT_ROOT>/Libraries/react-native/react-native-implementation'
module.name_mapper='^react-native$' -> '<PROJECT_ROOT>/index.js'
module.name_mapper='^react-native/\(.*\)$' -> '<PROJECT_ROOT>/\1'
module.name_mapper='^[./a-zA-Z0-9$_-]+\.\(bmp\|gif\|jpg\|jpeg\|png\|psd\|svg\|webp\|m4v\|mov\|mp4\|mpeg\|mpg\|webm\|aac\|aiff\|caf\|m4a\|mp3\|wav\|html\|pdf\)$' -> '<PROJECT_ROOT>/Libraries/Image/RelativeImageStub'

Expand Down
4 changes: 2 additions & 2 deletions .flowconfig.android
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
[include]

[libs]
Libraries/react-native/react-native-interface.js
interface.js
flow/

[options]
Expand All @@ -39,7 +39,7 @@ module.file_ext=.android.js

munge_underscores=true

module.name_mapper='^react-native$' -> '<PROJECT_ROOT>/Libraries/react-native/react-native-implementation'
module.name_mapper='^react-native$' -> '<PROJECT_ROOT>/index.js'
module.name_mapper='^react-native/\(.*\)$' -> '<PROJECT_ROOT>/\1'
module.name_mapper='^[./a-zA-Z0-9$_-]+\.\(bmp\|gif\|jpg\|jpeg\|png\|psd\|svg\|webp\|m4v\|mov\|mp4\|mpeg\|mpg\|webm\|aac\|aiff\|caf\|m4a\|mp3\|wav\|html\|pdf\)$' -> '<PROJECT_ROOT>/Libraries/Image/RelativeImageStub'

Expand Down
Loading

1 comment on commit e54ecf9

@elicwhite
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Heads up to @acoates-ms, this will probably require changed in Rn-windows

Please sign in to comment.