Skip to content

Commit

Permalink
fix: allow deprecated import path
Browse files Browse the repository at this point in the history
as discussed in facebook/react-native#13198 import paths in differ per RN version
  • Loading branch information
Tobias Eisenschenk committed Jul 2, 2019
1 parent a5e98b0 commit cbc818a
Show file tree
Hide file tree
Showing 4 changed files with 27 additions and 5 deletions.
8 changes: 4 additions & 4 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@

# OSX
#
.DS_Store
Expand All @@ -8,7 +7,6 @@
node_modules/
npm-debug.log
yarn-error.log


# Xcode
#
Expand All @@ -29,7 +27,6 @@ DerivedData
*.ipa
*.xcuserstate
project.xcworkspace


# Android/IntelliJ
#
Expand All @@ -39,8 +36,11 @@ build/
local.properties
*.iml

# VSCode
#
.vscode

# BUCK
buck-out/
\.buckd/
*.keystore

4 changes: 4 additions & 0 deletions ios/RNSelectableTextManager.h
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
#if __has_include(<RCTText/RCTBaseTextInputViewManager.h>)
#import <RCTText/RCTBaseTextInputViewManager.h>
#else
#import "RCTBaseTextInputViewManager.h"
#endif

NS_ASSUME_NONNULL_BEGIN

Expand Down
4 changes: 4 additions & 0 deletions ios/RNSelectableTextView.h
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
#if __has_include(<RCTText/RCTBaseTextInputView.h>)
#import <RCTText/RCTBaseTextInputView.h>
#else
#import "RCTBaseTextInputView.h"
#endif

NS_ASSUME_NONNULL_BEGIN

Expand Down
16 changes: 15 additions & 1 deletion ios/RNSelectableTextView.m
Original file line number Diff line number Diff line change
@@ -1,8 +1,22 @@

#if __has_include(<RCTText/RCTTextSelection.h>)
#import <RCTText/RCTTextSelection.h>
#else
#import "RCTTextSelection.h"
#endif

#if __has_include(<RCTText/RCTUITextView.h>)
#import <RCTText/RCTUITextView.h>
#else
#import "RCTUITextView.h"
#endif

#import "RNSelectableTextView.h"

#if __has_include(<RCTText/RCTTextAttributes.h>)
#import <RCTText/RCTTextAttributes.h>
#else
#import "RCTTextAttributes.h"
#endif

#import <React/RCTUtils.h>

Expand Down

0 comments on commit cbc818a

Please sign in to comment.