Skip to content

Instantly share code, notes, and snippets.

  • asdasd
  • asd
  • asdasd
  • asdasd
  • asdasd
  • asdasd

test test test

$math$ $$math$$ $$$math$$$

.fs\:0 { font-size: 0px; }
.fs\:0\.1 { font-size: 2px; }
.fs\:0\.2 { font-size: 4px; }
.fs\:0\.3 { font-size: 6px; }
.fs\:0\.4 { font-size: 8px; }
.fs\:0\.5 { font-size: 10px; }
.fs\:0\.6 { font-size: 12px; }
.fs\:0\.7 { font-size: 14px; }
.fs\:1 { font-size: 16px; }
.fs\:1\.1 { font-size: 18px; }
@zaydek-old
zaydek-old / App.js
Last active October 28, 2019 07:02
How I implemented dark mode on the unreleased preview of Codex.
// ...
// This is how I’m using `useDarkMode` in practice:
const [darkMode, setDarkMode] = useDarkMode()
React.useEffect(() => {
const html = document.querySelector("html")
if (darkMode) {
// Update the CSS variables:
html.setAttribute("data-dark-mode", "")
} else {
import fs from "fs"
import puppeteer from "puppeteer"
import React from "react"
import ReactDOM from "react-dom"
const headless = true
const selector = "article[contenteditable]"
const delay = 0
const text = fs.readFileSync("./src/components/test.md", "utf8")
import fs from "fs"
import puppeteer from "puppeteer"
import React from "react"
import ReactDOM from "react-dom"
const headless = true
const selector = "article[contenteditable]"
const delay = 0
const text = fs.readFileSync("./src/components/test.md", "utf8")
kill echo $(ps aux | grep chromium | awk '{ print $2 }')
import React from "react"
import ReactDOM from "react-dom"
import puppeteer from "puppeteer"
const selector = "article[contenteditable]"
let browser = null
let page = null
jest.setTimeout(30e3) // 30 seconds.
  1. asdasd

  2. sadsd 3. asdsds

  3. asdasd

  4. asdasd

  5. asdasd

  6. sadsd 3. asdsds

  7. asdasd

const MarkdownArray = [
// `<Comment />`.
{ syntax: /^\/\/(.*)(?:$|\n)/,
parser: (key, [children]) => <Comment key={key} children={parseText(children)} /> },
// `<Header />`.
{ syntax: /^(#{1,6})( .*)(?:$|\n)/,
parser: (key, [open, children]) => <Header key={key} open={open} children={parseText(children)} /> },