Generates a unique looking PDF from markdown
Hyperlinks may not be obvious so its best to put the urls in plain text in an appendix or bottom section (in case the end user prints it out)
import React, { Component } from 'react' | |
import TextField from 'material-ui/TextField' | |
/* | |
Using Material Design: | |
- set id to state key | |
- use a single handler to update state for n inputs | |
- no need to use formik or redux forms every time | |
*/ | |
export default class extends Component { |
#!/bin/bash | |
# usage ./create.sh your-bucket-name | |
# $1=your-bucket-name | |
# create a public bucket for images (your-bucket-name) | |
# create a logging bucket (s3-your-bucket-name) | |
# create bucket policy json: your-bucket-name.json | |
# set bucket policy | |
# create cloudfront config json: your-bucket-name-cf.json | |
# create a cloudfront distribution for the bucket using the logging bucket for logs |
import pg from 'pg' | |
import EventEmitter from 'events' | |
import util from 'util' | |
/* | |
initialize postgres client... | |
*/ | |
function PgEmitter() { | |
EventEmitter.call(this) | |
} |
import React, { memo } from 'react' | |
import { | |
Checkbox, | |
Button, | |
FormControlLabel, | |
TableBody, | |
TableCell, | |
TableFooter, | |
TableHead, | |
TableRow, |
import React, { useState } from 'react' | |
// assuming you have a custom fallback for a given param: id | |
const fallback = id => `https://fallback.distro.com/${id}.png` | |
const image = id => `https://images.distro.com/${id}.png` | |
export default props => { | |
const { click, id } = props | |