- Install docker
https://docs.docker.com/get-docker/
- Install psql
const fns = { | |
} | |
async function attemptConnection() { | |
return "Thanks!" | |
} | |
async function attemptPayment() { | |
throw new Error('Crapp!!') |
https://docs.docker.com/get-docker/
# https://plantuml.com/text-encoding | |
# https://github.com/dougn/python-plantuml/blob/master/plantuml.py#L64 | |
import zlib | |
import base64 | |
maketrans = bytes.maketrans | |
plantuml_alphabet = string.digits + string.ascii_uppercase + string.ascii_lowercase + '-_' | |
base64_alphabet = string.ascii_uppercase + string.ascii_lowercase + string.digits + '+/' |
# Forked from https://gist.github.com/dyno/94ef6bb9644a88d6981d6a1a9eb70802 | |
# https://plantuml.com/text-encoding | |
# https://github.com/dougn/python-plantuml/blob/master/plantuml.py#L64 | |
import zlib | |
import base64 | |
import string | |
plantuml_alphabet = string.digits + \ | |
string.ascii_uppercase + string.ascii_lowercase + '-_' |
function App() { | |
const [count, setCount] = useState(0); | |
// handler will be created on every render | |
const handleClick = () => { | |
setCount(count + 1); | |
}; | |
return ( | |
<SomePureComponent count={count} onClick={handleClick} /> |
# ./android/app/src/main/jni/Application.mk | |
APP_STL := c++_static |
# ./android/app/src/main/jni/Android.mk | |
# Set up paths | |
LOCAL_PATH := $(call my-dir) | |
include $(CLEAR_VARS) | |
# Debug mode | |
NDK_DEBUG=1 | |
# Specify C++ flags |
android { | |
// ... | |
defaultConfig { | |
// ... | |
// the following configures ndk-build to build a "helloworld" module | |
ndk { | |
abiFilters "armeabi-v7a", "x86" | |
moduleName "helloworld" | |
ldLibs "log" | |
} |
apply plugin: "com.android.application" | |
import com.android.build.OutputFile | |
/** | |
* The react.gradle file registers a task for each build variant (e.g. bundleDebugJsAndAssets | |
* and bundleReleaseJsAndAssets). | |
* These basically call `react-native bundle` with the correct arguments during the Android build | |
* cycle. By default, bundleDebugJsAndAssets is skipped, as in debug/dev mode we prefer to load the | |
* bundle directly from the development server. Below you can see all the possible configurations |
// ./android/app/src/main/java/com/cppreactnative/helloworld/HelloWorldModule.java | |
package com.cppreactnative.helloworld; | |
import com.facebook.react.bridge.Promise; | |
import com.facebook.react.bridge.ReactApplicationContext; | |
import com.facebook.react.bridge.ReactContextBaseJavaModule; | |
import com.facebook.react.bridge.ReactMethod; | |
public class HelloWorldModule extends ReactContextBaseJavaModule { |