sudo apt install zsh-autosuggestions zsh-syntax-highlighting zsh
import { Entypo, Feather } from '@expo/vector-icons'; | |
import faker from 'faker'; | |
import * as React from 'react'; | |
import { Dimensions, FlatList, Text, TouchableOpacity, View } from 'react-native'; | |
const { width, height } = Dimensions.get('screen'); | |
faker.seed(10); | |
const data = [...Array(20).keys()].map(() => ({ |
import 'package:flutter/material.dart'; | |
void main() => runApp(MyApp()); | |
class MyApp extends StatelessWidget { | |
// This widget is the root of your application. | |
@override | |
Widget build(BuildContext context) { | |
return MaterialApp( | |
title: 'Flutter Demo', |
Note
to active Office without crack, just follow https://github.com/WindowsAddict/IDM-Activation-Script,
you wiil only need to run
irm https://massgrave.dev/ias | iex
1. To enable TLS 1.2 in Android 4.4 | |
Copy TLSSocketFactory.java | |
If using HttpsURLConnection: | |
=> conn.setSSLSocketFactory(new TLSSocketFactory()); | |
Else if using OkHttp: | |
=> new OkHttpClient.Builder().setSocketFactory(new TLSSocketFactory()). ... .build(); | |
Else if using HttpClient: | |
sample for legacy apache http library: https://github.com/Kane-Shih/TestApacheHttpClient | |
=> see: https://stackoverflow.com/questions/2603691/android-httpclient-and-https |
allprojects {
...
afterEvaluate { project ->
def propsFile = rootProject.file('keystore.properties')
def configName = 'release'
if (propsFile.exists() && project.hasProperty("android") && project.android.signingConfigs.hasProperty(configName)) {
// No Security | |
{ | |
"rules": { | |
".read": true, | |
".write": true | |
} | |
} |
.... | |
public void startFacebook(String facebookUrl) { | |
try { | |
Uri uri = null; | |
int versionCode = getPackageManager() | |
.getPackageInfo("com.facebook.katana", 0) | |
.versionCode; |
I have two Github accounts: oanhnn (personal) and superman (for work). I want to use both accounts on same computer (without typing password everytime, when doing git push or pull).
Use ssh keys and define host aliases in ssh config file (each alias for an account).
public class ToolbarAlphaScrollBehavior extends CoordinatorLayout.Behavior<android.support.v7.widget.Toolbar> { | |
private ColorDrawable mStatusBarColorDrawable; | |
private int mStatusBarColor; | |
private TextView mTitleView; | |
private boolean searchedForTitleView = false; | |
public ToolbarAlphaScrollBehavior(Context context, AttributeSet attrs) { | |
super(context, attrs); | |
mStatusBarColor = ContextCompat.getColor(context, R.color.primary_dark); | |
mStatusBarColor = getColorWithAlpha(0, mStatusBarColor); |