Skip to content
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

[COMPILE ERROR] Property 'subscriptionPeriod' not found on object of type 'SKProduct *' #98

Closed
Suraj-Tiwari opened this issue Apr 4, 2018 · 4 comments

Comments

@Suraj-Tiwari
Copy link

Version of react-native-iap

Latest

Expected behavior

Successful Compile

Actual behavior

Crash While Compiling Issue is here file #ref

Steps to reprodue the behabior

  1. npm intall react-native-iap --save
  2. Manual link IOS (Library & Binary file)
    BUILD environment DEBUG compile. (Existing pod Project)
@hyochan
Copy link
Member

hyochan commented Apr 4, 2018

@Suraj-Tiwari I've just updated the readme and the published new version 0.3.1. Could you follow the readme once more? @neilco have gave us PR which might help manual installation for pod project.

@Suraj-Tiwari
Copy link
Author

Suraj-Tiwari commented Apr 5, 2018

I didn't used react-native link react-native-iap command
neither used pod install (Don't have any new library)

Problem occurs when i did

  1. npm intall react-native-iap --save
  2. open {project}.xcworkspace
  3. Manually link project
  4. Additional tries with/without (Project> Build Settings> Header Search Path> $(SRCROOT)/../node_modules/react-native-iap as recursive )

So last night I tried to do some workaround to resolve this issue & now updated from beta-5 to latest and it works perfectly.

@neilco
Copy link
Contributor

neilco commented Apr 10, 2018

For anyone else who hits this issue, this is where the error originates:

  if (@available(iOS 11.2, *)) {
    itemType = product.subscriptionPeriod ? @"sub" : @"iap";
  }

Since the module is using an API introduced in iOS 11.2, you'll need to use Xcode 9.2 or later in order to compile the iOS library.

@Suraj-Tiwari
Copy link
Author

@neilco yup you are right it was an xcode outdated version issue (as i was super lazy to udate :P ) Issue was fixed after i updated it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants