diff --git a/ONBOARDING.md b/ONBOARDING.md index f665a3a..0a71120 100644 --- a/ONBOARDING.md +++ b/ONBOARDING.md @@ -50,33 +50,25 @@ The sample app is a great way to test your changes and see the SDK in action. cd sample ``` -2. Install JavaScript dependencies: +2. Install dependencies (iOS pods are installed automatically via postinstall): ```bash yarn install ``` -3. Install iOS dependencies: - -```bash -cd ios -pod install -cd .. -``` - -4. Start the Metro bundler: +3. Start the Metro bundler: ```bash yarn start ``` -5. Open the iOS workspace: +4. Open the iOS workspace: ```bash open ios/MParticleSample.xcworkspace ``` -6. In Xcode: +5. In Xcode: - Select your target device/simulator - Update signing configuration if needed - Build and run (⌘R) diff --git a/sample/index.js b/sample/index.js index c43ba04..2a003f7 100644 --- a/sample/index.js +++ b/sample/index.js @@ -14,6 +14,11 @@ import { findNodeHandle, ScrollView, NativeEventEmitter, + SafeAreaView, + TextInput, + View, + TouchableOpacity, + KeyboardAvoidingView, } from 'react-native'; import MParticle from 'react-native-mparticle'; @@ -25,11 +30,14 @@ export default class MParticleSample extends Component { constructor(props) { super(props); this.placeholder1 = React.createRef(); - this.state = {isShowingText: true, + this.state = { + isShowingText: true, optedOut: true, attributionResults: "{value: no attributionResults}", session: '', - isKitActive: true}; + isKitActive: true, + customIdentifier: 'MSDKBottomSheetLayout', + }; this._toggleOptOut = this._toggleOptOut.bind(this) this._getAttributionResults = this._getAttributionResults.bind(this) @@ -235,67 +243,162 @@ export default class MParticleSample extends Component { let optAction = this.state.optedOut ? 'In' : 'Out' let kitActive = this.state.isKitActive ? 'true' : 'false' return ( - - - Welcome to React Native! {display} - - - Opted Out = {optedOut} - -