When making this website, i wanted a simple, reasonable way to make it look good on most displays. Not counting any minimization techniques, the following 58 bytes worked well for me:
main {
max-width: 38rem;
padding: 2rem;
margin: auto;
}
<!--ITEM TITLE--> | |
<h1 style="font-size:24px; font-weight:bold; margin-bottom:0;"> | |
<ITEM_TITLE_TEXT/> | |
</h1> | |
<!--DETAILS ABOUT THIS ITEM--> | |
<h2 style="font-size:20px; font-weight:bold; margin-top:32px; margin-bottom:3px;"> | |
Details About This Item | |
</h2> |
FROM hayd/alpine-deno:1.10.1 | |
WORKDIR /src/app | |
ADD deps.ts ./ | |
RUN ["deno", "cache", "deps.ts"] | |
ADD *.ts ./ | |
RUN ["deno", "cache", "mod.ts"] | |
ENTRYPOINT ["deno", "run", "--unstable", "--allow-net", "--allow-hrtime", "--allow-env", "--cached-only", "--no-check", "mod.ts"] |
import requests | |
import json | |
import pandas as pd | |
def airtable_download(table, params_dict={}, api_key=None, base_id=None, record_id=None): | |
"""Makes a request to Airtable for all records from a single table. | |
Returns data in dictionary format. | |
Keyword Arguments: |
#!/usr/bin/env python | |
import os | |
import sys | |
import argparse | |
import logging | |
from datetime import datetime, timedelta | |
from typing import List, Optional | |
from collections import defaultdict |
This will work with other flavours of Docker as well.
Run the following command:
docker run --name my-redis -p 6379:6379 --restart always --detach redis
This will download and run redis, set to auto-restart when your machine starts and bound to port 6379 on your machine.
class TooManyTriesException(BaseException): | |
pass | |
@font-face { | |
font-family: GT Walsheim Pro; | |
src: local("GT Walsheim Pro Regular"),local("GTWalsheimProRegular"),url(GTWalsheimProRegular.woff2) format("woff2"),url(GTWalsheimProRegular.woff) format("woff"),url(GTWalsheimProRegular.ttf) format("truetype"); | |
font-weight: 400; | |
font-style: normal | |
} | |
@font-face { | |
font-family: GT Walsheim Pro; | |
src: local("GT Walsheim Pro Bold"),local("GTWalsheimProBold"),url(GTWalsheimProBold.woff2) format("woff2"),url(GTWalsheimProBold.woff) format("woff"),url(GTWalsheimProBold.ttf) format("truetype"); |
import asyncio | |
import threading | |
import random | |
def thr(i): | |
# we need to create a new loop for the thread, and set it as the 'default' | |
# loop that will be returned by calls to asyncio.get_event_loop() from this | |
# thread. | |
loop = asyncio.new_event_loop() |