Skip to content

Instantly share code, notes, and snippets.

@newmedia2
newmedia2 / docker_wordpress.md
Created January 20, 2019 22:28 — forked from bradtraversy/docker_wordpress.md
Docker Compose FIle For Wordpress, MySQL & phpmyadmin

Wordpress & Docker

This file will setup Wordpress, MySQL & PHPMyAdmin with a single command. Add the code below to a file called "docker-compose.yaml" and run the command

$ docker-compose up -d

# To Tear Down
$ docker-compose down --volumes
@newmedia2
newmedia2 / fetch-api-with-async-await.markdown
Created April 12, 2020 16:23
Fetch API with async/await
@newmedia2
newmedia2 / animated-gradient-text.markdown
Created April 12, 2020 16:25
Animated Gradient Text
@newmedia2
newmedia2 / index.html
Created July 16, 2022 22:07
Simple Typing Carousel
<link href="https://fonts.googleapis.com/css?family=Raleway:200,100,400" rel="stylesheet" type="text/css" />
<h1>This pen is
<span
class="txt-rotate"
data-period="2000"
data-rotate='[ "nerdy.", "simple.", "pure JS.", "pretty.", "fun!" ]'></span>
</h1>
<h2>A single &lt;span&gt; is all you need.</h2>
@newmedia2
newmedia2 / index.html
Created July 16, 2022 22:18
Software Developer Homepage
<div class="vignette">
</div>
<div class="content come-in">
<header>
<div class="buttons">
<div></div>
<div></div>
<div></div>
</div>
<h1>gschier@Gregorys-Macbook-Pro: ~/projects (zsh)</h1>
@font-face {
font-family: SegoeUI;
src:
local("Segoe UI Light"),
url(//c.s-microsoft.com/static/fonts/segoe-ui/west-european/light/latest.woff2) format("woff2"),
url(//c.s-microsoft.com/static/fonts/segoe-ui/west-european/light/latest.woff) format("woff"),
url(//c.s-microsoft.com/static/fonts/segoe-ui/west-european/light/latest.ttf) format("truetype");
font-weight: 100;
}
@newmedia2
newmedia2 / index.html
Created August 1, 2022 14:16 — forked from prof3ssorSt3v3/index.html
Code from Video on building Custom Response Objects
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta name="viewport" content="width=device-width,initial-scale=1.0" />
<link rel="stylesheet" href="style.css" />
<script src="response.js" async defer></script>
<title>Custom Response</title>
</head>
@newmedia2
newmedia2 / .zshrc
Created January 24, 2023 18:53 — forked from bashbunni/.zshrc
CLI Pomodoro for Mac
# I'll be doing another one for Linux, but this one will give you
# a pop up notification and sound alert (using the built-in sounds for macOS)
# Requires https://github.com/caarlos0/timer to be installed
# Mac setup for pomo
alias work="timer 60m && terminal-notifier -message 'Pomodoro'\
-title 'Work Timer is up! Take a Break 😊'\
-appIcon '~/Pictures/pumpkin.png'\
-sound Crystal"
@newmedia2
newmedia2 / .zshrc
Created January 24, 2023 18:53 — forked from bashbunni/.zshrc
CLI Pomodoro for Linux
# study stream aliases
# Requires https://github.com/caarlos0/timer to be installed. spd-say should ship with your distro
declare -A pomo_options
pomo_options["work"]="45"
pomo_options["break"]="10"
pomodoro () {
if [ -n "$1" -a -n "${pomo_options["$1"]}" ]; then
val=$1
@newmedia2
newmedia2 / index.js
Created February 1, 2023 22:48 — forked from ihsangan/index.js
Send email from Workers with MailChannel API
async function readRequestBody(request) {
const { headers } = request;
const contentType = headers.get('content-type') || '';
if (contentType.includes('application/json')) {
return JSON.stringify(await request.json());
} else if (contentType.includes('form')) {
const formData = await request.formData();
const body = {};
for (const entry of formData.entries()) {
body[entry[0]] = entry[1];