-
Define interface for nested object, with [key: string]
export interface Item { id: number; size: number; } export interface Example {
name: string;
Define interface for nested object, with [key: string]
export interface Item {
id: number;
size: number;
}
export interface Example {
name: string;
/* | |
* Usage: | |
* const AppProvider = createProvider(rootReducer, rootSaga); | |
* ... | |
* <AppProvider> | |
* <AppComponent> | |
* </AppProvider> | |
*/ | |
const createProvider = (reducer, saga) => { | |
const sagaMiddleware = createSagaMiddleware(); |
# pull all git repo | |
alias git-pull-all="find . -maxdepth 3 -name .git -type d | rev | cut -c 6- | rev | xargs -I {} git -C {} pull" |
## To make sure ~/.bashrc gets autoladed when launching WSL | |
if [[ -f ~/.bashrc ]] ; then | |
. ~/.bashrc | |
fi | |
## To make sure ~/.zshrc gets autoladed when launching WSL | |
if [[ -f ~/.zshrc ]] ; then | |
. ~/.zshrc | |
fi |
# to generate your dhparam.pem file, run in the terminal | |
openssl dhparam -out /etc/nginx/ssl/dhparam.pem 2048 |
############### | |
# MODIFIED FOR SECURITY | |
# | |
# This assumes we have the following environmental variables setup through docker composer configuration | |
# MYSQL_DB | |
# MYSQL_USER | |
# MYSQL_PASSWORD | |
############### | |
# Backup |
#!/bin/bash | |
# | |
# /etc/rc.d/init.d/script_name | |
# script_name This shell script takes care of starting and stopping | |
# script_name (the Fedora Directory Server) | |
# | |
# Author: Brian Jones | |
# This e-mail address is being protected from spambots. You need JavaScript enabled to view it | |
# Taken from: https://www.linux.com/learn/managing-linux-daemons-init-scripts | |
# |
/* | |
* | |
* Fiddle: https://jsfiddle.net/w79L4wan/10/ | |
*/ | |
function ready(callback) { | |
// in case the document is already rendered | |
if (document.readyState!='loading') callback(); | |
// modern browsers | |
else if (document.addEventListener) document.addEventListener('DOMContentLoaded', callback); |