Skip to content

Instantly share code, notes, and snippets.

Jonathan Bell jonathanbell

Block or report user

Report or block jonathanbell

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@miguelmota
miguelmota / mount-fat32
Last active Jul 7, 2019
OS X mount FAT32 partition with read/write permissions
View mount-fat32
# diskutil list
diskutil unmount /dev/disk0s6
sudo mount -w -t msdos /dev/disk0s6 /Volumes/data
@adrianhall
adrianhall / .eslintrc.js
Last active Aug 6, 2019
A sample .eslintrc file
View .eslintrc.js
var OFF = 0, WARN = 1, ERROR = 2;
module.exports = exports = {
"env": {
"es6": true
},
"ecmaFeatures": {
// env=es6 doesn't include modules, which we are using
"modules": true
@cletusw
cletusw / .eslintrc
Last active Aug 14, 2019
ESLint Reset - A starter .eslintrc file that resets all rules to off and includes a description of what each rule does. From here, enable the rules that you care about by changing the 0 to a 1 or 2. 1 means warning (will not affect exit code) and 2 means error (will affect exit code).
View .eslintrc
{
// http://eslint.org/docs/rules/
"ecmaFeatures": {
"binaryLiterals": false, // enable binary literals
"blockBindings": false, // enable let and const (aka block bindings)
"defaultParams": false, // enable default function parameters
"forOf": false, // enable for-of loops
"generators": false, // enable generators
"objectLiteralComputedProperties": false, // enable computed object literal property names
@danawoodman
danawoodman / 0-react-hello-world.md
Last active Mar 4, 2019
React Hello World Examples
View 0-react-hello-world.md

React "Hello World" Examples

Below are a small collection of React examples to get anyone started using React. They progress from simpler to more complex/full featured.

They will hopefully get you over the initial learning curve of the hard parts of React (JSX, props vs. state, lifecycle events, etc).

Usage

You will want to create an index.html file and copy/paste the contents of 1-base.html and then create a scripts.js file and copy/paste the contents of one of the examples into it.

@ideag
ideag / jsfiddle-oembed.php
Last active Jul 10, 2016 — forked from ninnypants/gist-oembed.php
oEmbed JSFiddle links into WordPress posts
View jsfiddle-oembed.php
<?php
/*
Plugin Name: JSFiddle oEmbed
Plugin URI: http://klausk.aruno.lt/jsfiddle/
Description: Embed JSFiddle into posts
Version: 1.0
Author: IdeaG
Author URI: http://klausk.aruno.lt
License: GPL2
@nitinhayaran
nitinhayaran / flickr_urls
Last active May 10, 2018
Flickr Photo urls size suffixes along with url returned from apis
View flickr_urls
url_sq : s small square 75x75
url_q : q large square 150x150
url_t : t thumbnail, 100 on longest side
url_s : m small, 240 on longest side
url_n : n small, 320 on longest side
url_m : - medium, 500 on longest side
url_z : z medium 640, 640 on longest side
url_c : c medium 800, 800 on longest side†
url_l : b large, 1024 on longest side*
url_o : o original image, either a jpg, gif or png, depending on source format
@hkdobrev
hkdobrev / class-order.php
Last active Aug 13, 2019
PHP convention for the order in a class.
View class-order.php
<?php namespace Vendor\Library;
use Another\Vendor\Library\ClassName;
abstract class ClassName extends AnotherClass implements Countable, Serializable
{
const CONSTANTS = 'top';
use someTrait, anotherTrait {
anotherTrait::traitMethod insteadof someTrait;
@rxaviers
rxaviers / gist:7360908
Last active Aug 22, 2019
Complete list of github markdown emoji markup
View gist:7360908

People

:bowtie: :bowtie: 😄 :smile: 😆 :laughing:
😊 :blush: 😃 :smiley: ☺️ :relaxed:
😏 :smirk: 😍 :heart_eyes: 😘 :kissing_heart:
😚 :kissing_closed_eyes: 😳 :flushed: 😌 :relieved:
😆 :satisfied: 😁 :grin: 😉 :wink:
😜 :stuck_out_tongue_winking_eye: 😝 :stuck_out_tongue_closed_eyes: 😀 :grinning:
😗 :kissing: 😙 :kissing_smiling_eyes: 😛 :stuck_out_tongue:
@geksilla
geksilla / bootsrap_class_list
Last active Apr 9, 2019
Bootstrap css class list
View bootsrap_class_list
.navbar
.caret
.label
.table
.img-responsive
.img-rounded
.img-thumbnail
.img-circle
.sr-only
.lead
@Zirak
Zirak / gist:3086939
Last active Jul 11, 2019
xhr for dummies
View gist:3086939

So, you want to send a motherfucking XMLHttpRequest (XHR, or commonly and falsly known as AJAX.) Too bad, just ran out of motherfucking XMLHttpRequests; but I still have one regular. XHR is not magic. It does not autofuckinmagically send things the way you want them do be sent. It does not do the thinking for you. It just sends an Http Request.

You get a hold on such a prime beast like this:

You can’t perform that action at this time.