A ready to print version of the figma keyboard shortcuts for windows.
4000pixels wide (0.8 Mb)
8000pixels wide (2.1 Mb)
// Package twitter allows to do twitter oauth2 calls with the standard oauth2 package | |
// I created this public gist after hours spent trying to find something that works. | |
// This is copy paste from production code, with all database and framework specifics removed by hand, | |
// so I don't know if it works "as is". | |
package twitter | |
var ( | |
TWITTER_CONFIG = &oauth2.Config{ |
#!/bin/bash | |
esbuild --bundle --platform=node $* | node |
A ready to print version of the figma keyboard shortcuts for windows.
4000pixels wide (0.8 Mb)
8000pixels wide (2.1 Mb)
#!/bin/bash | |
# | |
# Convert an SVG file to a PDF file by using headless Chrome. | |
# | |
if [ $# -ne 2 ]; then | |
echo "Usage: ./svg2pdf.bash input.svg output.pdf" 1>&2 | |
exit 1 | |
fi |
// Inspired by | |
// https://github.com/rehooks/window-mouse-position/blob/master/index.js | |
import {useState,useEffect} from 'react' | |
export default function useMousePosition(){ | |
let [mousePosition, setMousePosition] = useState([0,0]) | |
function handleMouseMove(e) { | |
setMousePosition( [e.pageX, e.pageY] ); |
// We create a context interface with a reducer | |
import React, {createContext, useContext, useReducer} from 'react' | |
export const UserContext = createContext(); | |
export const UserProvider = ({reducer, initialState, children}) =>( | |
<UserContext.Provider value={useReducer(reducer,initialState)}> | |
{children} | |
</UserContext.Provider> | |
) |
import React from 'react' | |
import Logo from '../Logo'; | |
import Background from '../Background'; | |
import Header from '../Header'; | |
import Stats from '../Stats'; | |
import Timeline from '../Timeline'; | |
import useWindowSize from '../../effects/useWindowSize'; |
#cloud-config | |
preserve_hostname: false | |
fqdn: blog.kalena.app | |
hostname: blog.kalena.app | |
package_update: true | |
package_upgrade: true | |
package_reboot_if_required: true | |
packages: ['docker.io', 'ntp','libcap2-bin'] | |
resolv_conf: |
#cloud-config | |
preserve_hostname: false | |
fqdn: blog.kalena.app | |
hostname: blog.kalena.app | |
package_update: true | |
package_upgrade: true | |
package_reboot_if_required: true | |
packages: ['docker.io', 'ntp','libcap2-bin'] | |
resolv_conf: |
// Copyright 2015 Guillermo Alvarez. All rights reserved. | |
// Use of this source code is governed by standard BSD license. | |
/* | |
Package verbs provides a simple method to filter request method with the net/http ServeMux | |
func createUser(w http.ResponseWriter, r *http.Request) { | |
... | |
} | |
mux := http.NewServeMux() |