Since Twitter doesn't have an edit button, it's a suitable host for JavaScript modules.
Source tweet: https://twitter.com/rauchg/status/712799807073419264
const leftPad = await requireFromTwitter('712799807073419264');| import { useEffect, useState } from "react"; | |
| type UseTextSelectionReturn = { | |
| text: string; | |
| rects: DOMRect[]; | |
| ranges: Range[]; | |
| selection: Selection | null; | |
| }; | |
| const getRangesFromSelection = (selection: Selection): Range[] => { |
Since Twitter doesn't have an edit button, it's a suitable host for JavaScript modules.
Source tweet: https://twitter.com/rauchg/status/712799807073419264
const leftPad = await requireFromTwitter('712799807073419264');brew install git bash-completion
Configure things:
git config --global user.name "Your Name"
git config --global user.email "[email protected]"