Help with SQL commands to interact with a MySQL database
- Mac /usr/local/mysql/bin
- Windows /Program Files/MySQL/MySQL version/bin
- Xampp /xampp/mysql/bin
FROM node:10.15-alpine as base | |
RUN apk --no-cache --virtual build-dependencies add \ | |
python \ | |
make \ | |
g++ \ | |
&& rm -f /var/cache/apk/* \ | |
&& npm config set unsafe-perm true \ | |
&& npm install --quiet node-gyp -g --cache /tmp/empty-cache |
<template> | |
<div> | |
<input ref="input" type="text" v-model="localValue" /> | |
<slot :localValue="localValue" :formattedDate="formattedDate"> | |
{{ formattedDate }} | |
</slot> | |
<!-- parent can now use 'render prop through scoped slot' --> | |
<!-- | |
<DatePickerComponent slot-scope="{localValue, formattedDate}" :value="value" @input="handleChildInput" @clear="clearChildInput"> | |
{{ formattedDate }} |
$sizeUnit: rem | |
$marginKey: "m" | |
$paddingKey: "p" | |
$separator: "-" | |
$sizes: ("none", 0), ("auto", auto), ("xxs", 0.125), ("xs", 0.25), ("sm", 0.5), ("md", 1), ("lg", 2), ("xl", 4), ("xxl", 8) | |
$positions: ("t", "top"), ("r", "right"), ("b", "bottom"), ("l", "left") | |
@function sizeValue($key, $value) | |
@return if($key == "none" or $key == "auto", $value, $value + $sizeUnit) |
PX | REM | TW | |
---|---|---|---|
4 | 0.25 | 1 | |
8 | 0.5 | 2 | |
16 | 1 | 4 | |
32 | 2 | 8 | |
48 | 3 | 12 | |
64 | 4 | 16 | |
80 | 5 | 20 | |
96 | 6 | 24 | |
112 | 7 | 28 |
function parseJwt (token) { | |
var base64Url = token.split('.')[1]; | |
var base64 = base64Url.replace('-', '+').replace('_', '/'); | |
return JSON.parse(window.atob(base64)); | |
}; |
<?php | |
/** | |
* Grab the url of a publicly embeddable video hosted on vimeo | |
* @param str $video_url The "embed" url of a video | |
* @return str The url of the thumbnail, or false if there's an error | |
*/ | |
function grab_vimeo_thumbnail($vimeo_url){ | |
if( !$vimeo_url ) return false; | |
$data = json_decode( file_get_contents( 'http://vimeo.com/api/oembed.json?url=' . $vimeo_url ) ); |
<?php | |
namespace Src\Csv; | |
use Illuminate\Http\Response; | |
use Symfony\Component\HttpFoundation\StreamedResponse; | |
/** | |
* Class DownloadLargeCsv | |
* |
#!/bin/bash | |
usage() { echo "usage: --coursename [--coursename \"build-a-react-app-with-redux\"] --type [--type \"courses|lessons\"]" 1>&2; exit 1; } | |
OPTS=$(getopt -o c:t: --long coursename:,type: -n 'download_egghead_videos.sh' -- "$@") | |
if [ $? != 0 ] ; then echo "Terminating..." >&2 ; exit 1 ; fi | |
eval set -- "$OPTS" |