Skip to content

Instantly share code, notes, and snippets.

View publicJorn's full-sized avatar

Jorn Luiten publicJorn

  • frontrain
  • Netherlands
View GitHub Profile
@publicJorn
publicJorn / html5.html
Last active August 29, 2015 13:58
minimalistic html5 template for quick tests
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width">
<meta name="description" content="">
<title></title>
@publicJorn
publicJorn / .gitconfig
Created May 21, 2014 07:06
default git config, copied from @dandydev
[alias]
# Korte log van de laatste 20 commits met enkel SHA's en omschrijving.
l = log --pretty=oneline -n 20 --graph
# Gecondenseerde versie van status. Handig als snel overzicht.
s = status -s
# Status shorthand
st = status
# Laat diff zien tussen laatste commit en huidige staat van working copy
d = !"git diff-index --quiet HEAD -- || clear; git diff --patch-with-stat"
# `git di $number` laat diff zien tussen huidige staat en $number revisions geleden
@publicJorn
publicJorn / jquery-plugin-template.js
Last active November 19, 2021 08:47
jQuery plugin template
/**
* jQuery plugin template by https://github.com/publicJorn
* Features:
* - dynamic plugin name (only supply once) so it's easy to change later
* - plugin factory to make it work in the browser, or with AMD / COMMONJS modules
* - Plugin instance is saved on the selector element
* - Default options are saved to the instance in case you need to figure out a difference between passed options
*/
(function(global, factory) {
'use strict';
@publicJorn
publicJorn / reactES6.jsx
Last active January 14, 2016 14:57
React component in ES6 class syntax
import React, {Component} from 'react';
export class MyComponent extends Component {
constructor (props) {
super(props);
}
render () {
return (
<p>
@publicJorn
publicJorn / html-ie-tag.html
Created February 2, 2016 11:52
IE conditional comments set class on html tag
<!DOCTYPE html>
<!-- (remove me)
Also consider setting:
class `no-js` : remove (or set to `js`) with javascript
-->
<!--[if IEMobile 7 ]> <html dir="ltr" lang="nl" class="iem7"> <![endif]-->
<!--[if lt IE 7 ]> <html dir="ltr" lang="nl" class="ie6 oldie"> <![endif]-->
<!--[if IE 7 ]> <html dir="ltr" lang="nl" class="ie7 oldie"> <![endif]-->
@publicJorn
publicJorn / .editorconfig
Last active April 11, 2016 14:28
My preferred .editorconfig settings
root = true
[*]
charset = utf-8
end_of_line = lf
insert_final_newline = true
max_line_length = off
trim_trailing_whitespace = true
indent_style = space
indent_size = 2
@publicJorn
publicJorn / dev-breakpoints.css
Last active July 5, 2016 15:06
Shows the breakpoint in the upper left corner.
body::before {
position: fixed;
top: 0;
left: 0;
z-index: 100000;
box-sizing: border-box;
display: block;
padding: 5px;
font-size: 12px;
font-family: sans-serif;
@publicJorn
publicJorn / jquery-plugin-template-es6.js
Last active June 4, 2023 21:43
jQuery plugin template ES6
/**
* jQuery plugin template by https://github.com/publicJorn
* Features:
* - ES6 (So, it requires a build step to transpile to ES5 for most environments)
* - Dynamic plugin name (only supply once) so it's easy to change later
* - Plugin factory to make it work in the browser, or with AMD / COMMONJS modules
* - Plugin instance is saved on the selector element
* - Default options are saved to the instance in case you need to figure out a difference between passed options
*/
(function(global, factory) {
@publicJorn
publicJorn / singleton.dart
Last active April 25, 2020 11:17
Dart singleton explained. Try it out in https://dartpad.dev/
import 'dart:math';
class Randy {
String say;
int nr;
// Note: Randy constructs with a RANDOM number
Randy(say) {
this.say = say;
@publicJorn
publicJorn / multiple-ssh-keys-for-git.md
Last active June 17, 2022 16:41
How to setup extra ssh keys when using different

Setup multiple SSH Keys for different github accounts

For osx

Create different public key

Create different ssh key according the article: Generate new SSH key

$ ssh-keygen -t ed25519 -C "my_email@provider.com"