Each of these commands will run an ad hoc http static server in your current (or specified) directory, available at http://localhost:8000. Use this power wisely.
$ python -m SimpleHTTPServer 8000
public static class ExampleViewHolder extends RecyclerView.ViewHolder | |
implements View.OnClickListener { | |
private int originalHeight = 0; | |
private boolean isViewExpanded = false; | |
private YourCustomView yourCustomView | |
public ExampleViewHolder(View v) { | |
super(v); | |
v.setOnClickListener(this); |
Math.floor(((new Date('2019-01-01')).getDay()*24*60*60*1000 + (new Date('2019-11-08')).getTime() - (new Date('2019-01-01')).getTime())/1000/60/60/24/7 + 1) |
Each of these commands will run an ad hoc http static server in your current (or specified) directory, available at http://localhost:8000. Use this power wisely.
$ python -m SimpleHTTPServer 8000
convert *.png -resize 600x -set filename:t '%t' 'resized_%[filename:t].jpg' | |
convert -append resized_*.jpg result.jpg |
dependencies { | |
/* | |
AndroidX | |
https://developer.android.com/jetpack/androidx/migrate/artifact-mappings | |
*/ | |
implementation "androidx.constraintlayout:constraintlayout:x.y.z" | |
/* | |
Material Components |
import React, { useEffect, useRef, useState } from 'react'; | |
import { StyleSheet } from 'react-native'; | |
import AsyncStorage from '@react-native-async-storage/async-storage'; | |
import { SafeAreaView } from 'react-native-safe-area-context'; | |
import WebView, { WebViewMessageEvent } from 'react-native-webview'; | |
import { StatusBar } from 'expo-status-bar'; | |
enum MessageTypes { |
#!/usr/bin/env zsh | |
sudo rm -f /usr/bin/node | |
sudo rm -f /usr/bin/npm | |
sudo ln -s $(which node) /usr/bin/ | |
sudo ln -s $(which npm) /usr/bin/ |
#!/usr/bin/env bash -e | |
## | |
## Automatic version from package.json file | |
## | |
## Call this script from your XCode Scheme: | |
## - Copy / paste this script in a .sh file | |
## - Open your app scheme in XCode (shortcut: Cmd + <) | |
## - go to Build > Pre-actions | |
## - Add a run Script ('+' button in scheme window > "New Run Script Action" |
// source: | |
// https://stackoverflow.com/questions/24750186/i-cant-get-properties-of-a-class-using-swift-by-class-copypropertylist | |
import Foundation | |
extension NSObject { | |
func dictionaryRepresentation() -> [String: Any] { |