This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import addToMailchimp from 'gatsby-plugin-mailchimp'; | |
import React, { useState } from 'react'; | |
import * as styles from './EmailListForm.module.scss'; | |
const EmailListForm: React.FunctionComponent<{}> = () => { | |
const [email, setEmail] = useState(''); | |
const handleSubmit = (e: React.FormEvent<HTMLFormElement>) => { | |
e.preventDefault(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// See tth.im/s3json for a full explanation of this code | |
const AWS = require('aws-sdk'); | |
const S3 = new AWS.S3(); | |
exports.handler = async (_, context) => { | |
try { | |
const query = 'SELECT * FROM s3object[*].results[*] r;'; | |
// test query is against data from https://swapi.co/api/planets/?page=2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { graphql, StaticQuery } from 'gatsby'; | |
import * as React from 'react'; | |
import { Helmet as ReactHelmet } from 'react-helmet'; | |
interface HelmetProps { | |
pageTitle?: string; | |
} | |
interface HelmetDataProps extends HelmetProps { | |
data: { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { graphql, StaticQuery } from 'gatsby'; | |
import * as React from 'react'; | |
interface HeaderProps { | |
className: string; | |
} | |
interface HeaderPropsWithData extends HeaderProps { | |
data: { | |
site: { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Mount the font tools dmg as a volume on your Mac | |
hdiutil attach ~/Downloads/osxfonttools.dmg | |
# Navigate into the volume and copy | |
# the main .pkg file somewhere locally | |
# so you can manipulate it | |
cd /Volumes/OS\ X\ Font\ Tools/ | |
pkgutil --expand OS\ X\ Font\ Tools.pkg ~/fontTools && cd ~/fontTools | |
# If you ls, here's what's in the file |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
p#notice #{notice} | |
h1 <%= plural_table_name.titleize %> | |
table | |
thead | |
tr | |
<% attributes.reject(&:password_digest?).each do |attribute| -%> | |
th <%= attribute.human_name %> | |
<% end -%> | |
th colspan="3" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<p id="notice"><%%= notice %></p> | |
<h1><%= plural_table_name.titleize %></h1> | |
<table> | |
<thead> | |
<tr> | |
<% attributes.reject(&:password_digest?).each do |attribute| -%> | |
<th><%= attribute.human_name %></th> | |
<% end -%> |