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
Wait a second, why would you want to give out the secrets?!? Because its not a secret anymore and besides, why shouldn't everyone and their neighbors be able to create a plethora of these useless yet exciting math bits? The information in this article took me a few weeks to compile and what works for me is not guaranteed to work for you. Please use this guide as a starting point to learn a bit about C programming and compiling software.
This week NN Group released a video by Jakob Nielsen in which he attempts to help designers deal with the problem of customers being resistant to their new site/product redesign. The argument goes thusly:
There's slightly more to it than that, he caveats his argument with requiring you to have of course followed their best practices on product design, and allows for a period of customers being able to elect to continue to use the old site, although he says this is obviously only a temporary solution as you don't want to support both.
<script> | |
let todos = []; | |
let duration = ''; | |
function timeit(fn) { | |
let start = Date.now(); | |
fn(); | |
setTimeout(() => { | |
duration += ' + ' + (Date.now() - start); | |
}, 10); |
import React, { useState, useEffect } from 'react' | |
import styled from 'styled-components' | |
import { useCanvas } from 'utils/hooks' | |
import debounce from 'lodash/debounce' | |
export default function Glow() { | |
const [ref, setRef] = useState<HTMLCanvasElement | null>(null) | |
const [boxes, setBoxes] = useState<Box[]>([]) | |
const [ctx, width, height] = useCanvas(ref) | |
const moving = useMouseMoving() |