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;
}
int | |
msleep(int ms) { | |
struct timespec req = {0}, rem; | |
int r = ms / 1000; | |
if(r >= 1) { | |
req.tv_sec = r; | |
ms -= r * 1000; | |
} | |
if(ms) |
$ grep -P "^[ABCDEFabcdefOoIi]{6,6}$" /usr/share/dict/words | tr 'OoIi' '0011' | tr '[:lower:]' '[:upper:]' | awk '{print "#" $0}' | |
#ACAD1A | |
#B0BB1E | |
#DEBB1E | |
#AB1DED | |
#ACAC1A | |
#ACCEDE | |
#AC1D1C | |
#BAB1ED | |
#BA0BAB |
import React from "react"; | |
import {ImageBackground} from "react-native"; | |
export function Sprite(props) { | |
const [w, h] = [props.geometry.width, props.geometry.height]; | |
const r = Math.min(w / (props.width / props.cols), h / (props.height / props.rows)); | |
return ( | |
<ImageBackground | |
source={props.source} |
/** | |
* Simple green pass decoder inspired by https://git.gir.st/greenpass.git/blob_plain/master:/greenpass.py | |
* | |
* 2021 Lorenzo Millucci | |
* | |
* Before usage install following dependecies `npm install base45 cbor jpeg-js jsqr pako` | |
*/ | |
const base45 = require('base45'); | |
const cbor = require('cbor'); |
const crypto = require("crypto"); | |
// larger numbers mean better security | |
const config = { | |
// size of the generated hash | |
hashBytes: 32, | |
// larger salt means hashed passwords are more resistant to rainbow table, but | |
// you get diminishing returns pretty fast | |
saltBytes: 16, | |
// more iterations means an attacker has to take longer to brute force an |
While the public API intended for users to use is the scheduler
package, the reconciler currently
does not use scheduler
's priority classes internally.
ReactFiberScheduler
has its own internal "mini-scheduler" that uses the scheduler
package
indirectly for its deadline-capable scheduleCallback.
This is kind of a documentation of implementation details that I suppose will be gone by the end of the year, but what can you do.
/* | |
* This is free and unencumbered software released into the public domain. | |
* | |
* For more information, please refer to <https://unlicense.org> | |
*/ | |
//Regular text | |
#define BLK "\e[0;30m" | |
#define RED "\e[0;31m" | |
#define GRN "\e[0;32m" |
/* | |
Once upon a time, on a way through the old wild west,… | |
… a man was given directions to go from one point to another. The directions were "NORTH", "SOUTH", "WEST", "EAST". Clearly "NORTH" and "SOUTH" are opposite, "WEST" and "EAST" too. Going to one direction and coming back the opposite direction is a needless effort. Since this is the wild west, with dreadfull weather and not much water, it's important to save yourself some energy, otherwise you might die of thirst! | |
How I crossed the desert the smart way. | |
The directions given to the man are, for example, the following: | |
["NORTH", "SOUTH", "SOUTH", "EAST", "WEST", "NORTH", "WEST"]. | |
You can immediatly see that going "NORTH" and then "SOUTH" is not reasonable, better stay to the same place! | |
So the task is to give to the man a simplified version of the plan. | |
A better plan in this case is simply: | |
["WEST"] |
/** | |
* dwmconfig.h | |
* Hardware multimedia keys | |
*/ | |
/* Somewhere at the beginning of config.h include: */ | |
/* | |
You obviously need the X11 development packages installed, X11proto in particular, but | |
here is the location of the keysyms header upstream copy if you can't bother | |
using the contents of your own hard drive. ;-P |