-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.js
More file actions
19 lines (15 loc) · 1015 Bytes
/
index.js
File metadata and controls
19 lines (15 loc) · 1015 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
import { NativeModules, Platform } from 'react-native'
const { MageReact } = NativeModules
export const Mage = MageReact
// function throwNumericAttributeNameWarning(methodName, attributeName, attribute){
// methodName = methodName + "(" + attributeName + "," + attribute + ")"
// console.warn("Mage SDK:", methodName, "called with a numeric variable name:", attributeName, "as a first argument. This is not allowed and the attribut is not passed to the API!")
// }
// function throwAttributeValueWarning(methodName, attributeName, attribute, typeNeeded){
// methodName = methodName + "(" + attributeName + "," + attribute + ")"
// console.warn("Mage SDK:", methodName, "called with a non", typeNeeded ,"variable type", typeof(attribute), "as a second argument. This is not allowed and the attribut is not passed to the API!")
// }
// Mage.userPurchased is unavailable and not needed on iOS devices due to our auto tracking purchases feature
if (Platform.OS === 'ios'){
Mage.userPurchased = () => {}
}