Skip to content

Instantly share code, notes, and snippets.

@gaearon
gaearon / prepack-gentle-intro-1.md
Last active February 13, 2024 14:30
A Gentle Introduction to Prepack, Part 1

Note:

When this guide is more complete, the plan is to move it into Prepack documentation.
For now I put it out as a gist to gather initial feedback.

A Gentle Introduction to Prepack (Part 1)

If you're building JavaScript apps, you might already be familiar with some tools that compile JavaScript code to equivalent JavaScript code:

  • Babel lets you use newer JavaScript language features, and outputs equivalent code that targets older JavaScript engines.
@Geoff-Ford
Geoff-Ford / composing-software.md
Last active March 3, 2024 08:48
Eric Elliott's Composing Software Series

Eric Elliott's "Composing Software" Series

A collection of links to the excellent "Composing Software" series of medium stories by Eric Elliott.

Edit: I see that each post in the series now has index, previous and next links. However, they don't follow a linear flow through all the articles with some pointing back to previous posts effectively locking you in a loop.

@jbellenger
jbellenger / NamedChunksPlugin.js
Last active July 21, 2017 15:36
named chunks
// All webpack chunks have an identifier that is written to both the chunk and
// the chunk manifest.
//
// By default, webpack uses "int" identifiers, where the identifiers are
// sequentially generated after chunks are ordered by OccurenceOrderPlugin.
//
// The result of this is that small code changes may cause chunks to be
// reordered, leading to a cascading change of chunk ids, and a large number of
// chunk rehashes that could have been avoided.
//
package main
import (
"bytes"
"io/ioutil"
"log"
"net/http"
"os"
"time"
unbind C-b
set -g prefix C-b
#urxvt tab like window switching (-n: no prior escape seq)
bind -n M-down new-window
bind -n M-left prev
bind -n M-right next
#bind -n C-left swap-window -t -1
#bind -n C-right swap-window -t +1
@juhaelee
juhaelee / react-typescript.md
Last active January 26, 2023 00:52
React + Typescript Cheatsheet

React + Typescript Cheatsheet

Setup

If you use atom... download & install the following packages:

What are Typescript type definition files? (*.d.ts)

@ipbastola
ipbastola / clean-up-boot-partition-ubuntu.md
Last active April 3, 2024 06:54
Safest way to clean up boot partition - Ubuntu 14.04LTS-x64, Ubuntu 16.04LTS-x64

Safest way to clean up boot partition - Ubuntu 14.04LTS-x64, Ubuntu 16.04LTS-x64

Reference

Case I: if /boot is not 100% full and apt is working

1. Check the current kernel version

$ uname -r 
== For 64 bit arch
1. Download oracle-instantclient12.1-basic-12.1.0.2.0-1.x86_64.rpm and oracle-instantclient12.1-devel-12.1.0.2.0-1.x86_64.rpm from Oracle site
2. install alien: sudo apt-get install alien
3. install oracle instal client:
3.1 sudo alien -i oracle-instantclient12.1-basic-12.1.0.2.0-1.x86_64.rpm
3.2 sudo alien -i oracle-instantclient12.1-devel-12.1.0.2.0-1.x86_64.rpm
4. install php package
4.1 sudo apt-get install php5-dev
4.2 sudo apt-get install libcurl3-openssl-dev
@nivv
nivv / PHP 7 - Installing imagick on Ubuntu 14.04.md
Last active November 28, 2021 11:38
Guide - Enable imagick on PHP7

Guide

Note The extension Imagick is now included in Ondrej's PPA. All you need to do now is $ sudo apt-get install php-imagick, and you're done. I'll keep the guide here because a lot of it is still true for other extensions

======

I've installed PHP7 via Ondrej's PPA. He maintains these PPA's on his free time, consider donating

Install dependencies

@pascalbaljet
pascalbaljet / imagick-3.4.0-PHP7-forge.sh
Last active November 26, 2020 09:10
Install Imagick 3.4.0 on PHP 7.0 server (Laravel Forge)
#!/bin/bash
if [ "$EUID" -ne 0 ]
then echo "Please run as root"
exit
fi
apt-get install pkg-config libmagickwand-dev -y
cd /tmp
wget https://pecl.php.net/get/imagick-3.4.0.tgz
tar xvzf imagick-3.4.0.tgz