This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import React from 'react' | |
| import Router from './Router' | |
| class App extends React.Component { | |
| render() { | |
| return ( | |
| <Router /> | |
| ) | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package com.splashscreenreactnative; | |
| import android.content.Intent; | |
| import android.os.Bundle; | |
| import android.support.v7.app.AppCompatActivity; | |
| public class SplashActivity extends AppCompatActivity { | |
| @Override | |
| protected void onCreate(Bundle savedInstanceState) { | |
| super.onCreate(savedInstanceState); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <manifest xmlns:android="http://schemas.android.com/apk/res/android" | |
| package="com.splashscreenreactnative"> | |
| <uses-permission android:name="android.permission.INTERNET" /> | |
| <uses-permission android:name="android.permission.SYSTEM_ALERT_WINDOW"/> | |
| <application | |
| android:name=".MainApplication" | |
| android:label="@string/app_name" | |
| android:icon="@mipmap/ic_launcher" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <activity | |
| android:name=".MainActivity" | |
| android:label="@string/app_name" | |
| android:configChanges="keyboard|keyboardHidden|orientation|screenSize" | |
| android:windowSoftInputMode="adjustResize" | |
| android:exported="true" | |
| > | |
| <intent-filter> | |
| <action android:name="android.intent.action.MAIN" /> | |
| <!-- <category android:name="android.intent.category.LAUNCHER" /> --> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <activity | |
| android:name=".SplashActivity" | |
| android:theme="@style/SplashTheme" | |
| android:label="@string/app_name"> | |
| <intent-filter> | |
| <action android:name="android.intent.action.MAIN" /> | |
| <category android:name="android.intent.category.LAUNCHER" /> | |
| </intent-filter> | |
| </activity> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <resources> | |
| <!-- Base application theme. --> | |
| <style name="AppTheme" parent="Theme.AppCompat.Light.NoActionBar"> | |
| <!-- Customize your theme here. --> | |
| <item name="android:statusBarColor">@color/white</item> | |
| </style> | |
| <style name="SplashTheme" parent="Theme.AppCompat.Light.NoActionBar"> | |
| <item name="android:windowBackground">@drawable/background_splash</item> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?xml version="1.0" encoding="utf-8"?> | |
| <resources> | |
| <color name="white">#fff</color> | |
| </resources> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?xml version="1.0" encoding="utf-8"?> | |
| <layer-list xmlns:android="http://schemas.android.com/apk/res/android"> | |
| <item | |
| android:drawable="@color/blue"/> | |
| <item | |
| android:width="200dp" | |
| android:height="200dp" | |
| android:drawable="@mipmap/icon" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import React, { Component } from 'react' | |
| import { | |
| View, | |
| WebView, | |
| ActivityIndicator | |
| } from 'react-native' | |
| import axios from 'axios' | |
| export default class Paypal extends Component { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| axios.post('https://api.sandbox.paypal.com/v1/oauth2/token', { grant_type: 'client_credentials' }, | |
| { | |
| headers: { | |
| 'Content-Type': 'application/x-www-form-urlencoded', | |
| 'Authorization': ` ` // Your Authorization Value | |
| } | |
| } | |
| ) | |
| .then(response => { | |
| console.log(response.data.access_token) |