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
// @flow | |
import { NativeModules } from 'react-native'; | |
const { MyLibrary } = NativeModules; | |
interface ToastOptions { | |
message: string; | |
duration?: number; | |
} | |
interface IToast { |
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.reactlibrary; | |
import android.graphics.Color; | |
import android.view.View; | |
import android.widget.TextView; | |
import android.widget.Toast; | |
import com.facebook.react.bridge.Callback; | |
import com.facebook.react.bridge.ReactApplicationContext; | |
import com.facebook.react.bridge.ReactContextBaseJavaModule; |
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
fun main(args: Array<String>) { | |
print("dilip".lastChar()) | |
} | |
fun String.lastChar() = this.get(this.length - 1) |
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
class MainActivity : AppCompatActivity() { | |
companion object { | |
const val RC_CODE = 101 | |
const val TAG = "debug_MainActivity" | |
const val SENT = "SMS_SENT" | |
const val DELIVERED = "SMS_DELIVERED" | |
} | |
// Views |
NewerOlder