A tweet-sized debugger for visualizing your CSS layouts. Outlines every DOM element on your page a random (valid) CSS hex color.
One-line version to paste in your DevTools
Use $$
if your browser aliases it:
~ 108 byte version
// https://gist.github.com/theednaffattack/790b3dc87d3c0c02227c2494e5daf15e | |
import { Button as MyButton, ButtonProps, Text } from "rebass"; | |
import { | |
borderRadius, | |
boxShadow, | |
BorderRadiusProps, | |
BoxShadowProps, | |
TLengthStyledSystem | |
} from "styled-system"; |
// These are the introspection queries (note POST method) by GraphQL Playground | |
2019-07-18T22:14:14.319808+00:00 heroku[router]: at=info method=POST path="/graphql" host=eddie-faux-gram.herokuapp.com request_id=458285a3-d959-453b-b259-3440c13647dc fwd="73.70.116.10" dyno=web.1 connect=1ms service=7ms status=500 bytes=429 protocol=https | |
// These are subscriptions | |
2019-07-18T22:14:18.412631+00:00 heroku[router]: at=info method=GET path="/subscriptions" host=eddie-faux-gram.herokuapp.com request_id=4c0b335a-a4fc-4906-a899-9ca74c36ff0f fwd="73.70.116.10" dyno=web.1 connect=1ms service=191ms status=101 bytes=165 protocol=http |
const React = require("react") | |
const ReactDOM = require("react-dom") | |
const Meep = ( | |
<div | |
style={{ backgroundColor: "blue", fontColor: "white" }} | |
onClick={() => alert("hello")} | |
> | |
Hello world? | |
</div> |
// ROOT/server.js | |
const express = require("express") | |
const { renderToString } = require("react-dom/server") | |
const { ServerStyleSheet } = require("styled-components") | |
const SSR = require("./static") | |
const { Meep: ReactSSR } = require("./src/ssr") |
// APP_ROOT/server.js | |
const { Meep: ReactSSR } = require("./src/ssr") | |
const sheet = new ServerStyleSheet() | |
try { | |
const html = renderToString(sheet.collectStyles(<ReactSSR />)) | |
const styleTags = sheet.getStyleTags() // or sheet.getStyleElement(); | |
} catch (error) { | |
// handle error |
There are two main modes to run the Let's Encrypt client (called Certbot
):
Webroot is better because it doesn't need to replace Nginx (to bind to port 80).
In the following, we're setting up mydomain.com
.
HTML is served from /var/www/mydomain
, and challenges are served from /var/www/letsencrypt
.
[user] | |
name = Eddie Naff | |
email = eddienaff@gmail.com | |
[core] | |
editor = vim | |
whitespace = fix,-indent-with-non-tab,trailing-space,cr-at-eol | |
excludesfile = ~/.gitignore | |
[sendemail] | |
smtpencryption = tls | |
smtpserver = smtp.gmail.com |
// get Data from a URI and then run whatever function we want using that data
function getData(dataURI, thingToRun) {
var myData = getSomeData();
thingToRun(myData);
}
// the function we're passing as a callback