Skip to content

Instantly share code, notes, and snippets.

View Phunky's full-sized avatar

Mark Harwood Phunky

View GitHub Profile
@Phunky
Phunky / SassMeister-input-HTML.html
Last active August 29, 2015 14:11
Generated by SassMeister.com.
Make a mixin instead of nesting
@Phunky
Phunky / 0_reuse_code.js
Last active August 29, 2015 14:11
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
@Phunky
Phunky / gist:34e3944d4b9304622bcb
Created January 27, 2015 15:51
AutoHotKey config for OSX Keyboard on Windows and Linux. As in proper 1:1 keyboard mappings for those used to British OSX keyboard layout
#z::Run www.autohotkey.com
; Swap CMD and CTRL around
LWin::Ctrl
; Select start
^Left::
Send, {Home}
return
@Phunky
Phunky / gist:0a3de8d986a7b9b72fd3
Created April 16, 2015 15:43
base16-ocean.dark.tmTheme
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>author</key>
<string>Chris Kempson (http://chriskempson.com)</string>
<key>name</key>
<string>Base16 Ocean Dark</string>
<key>semanticClass</key>
<string>base16.ocean.dark</string>
@Phunky
Phunky / SassMeister-input-HTML.html
Created May 11, 2015 15:05
Generated by SassMeister.com.
<div class="color">
<div class="___blue-grey_light4"></div>
<div class="___blue-grey_light3"></div>
<div class="___blue-grey_light2"></div>
<div class="___blue-grey_light1"></div>
<div class="___blue-grey"></div>
<div class="___blue-grey_dark1"></div>
<div class="___blue-grey_dark2"></div>
<div class="___blue-grey_dark3"></div>
<div class="___blue-grey_dark4"></div>
@Phunky
Phunky / gist:b36c9c786c43de3ab2a5
Created May 14, 2015 16:56
Simple MySQLi wrapper idea... named after MariaDB as it would only be for MySQLi!
<?php
// Records
$Maria->user()->insert(['name'=>'Bobby']);
$Maria->user(1)->delete();
$Maria->user(1)->read();
$Maria->user(1)->update('name', 'bobby');
@Phunky
Phunky / SassMeister-input-HTML.html
Created May 29, 2015 10:58
Generated by SassMeister.com.
<a class="ui-btn" href="#">Button</a>
<br/><br/>
<div class="ui-btn-group">
<a data-trigger="uiBtnGroupToggle" class="ui-btn"><i class="icon-align-left"></i> Left</a>
<a data-trigger="uiBtnGroupToggle" class="ui-btn"><i class="icon-align-center"></i> Center</a>
<a data-trigger="uiBtnGroupToggle" class="ui-btn"><i class="icon-align-right"></i> Right</a>
</div>
@Phunky
Phunky / slim.php
Last active August 29, 2015 14:27
What is the best way to allow me to pass data down to my views for all routes via middleware
<?php
// Middleware for all requests
$app->add(function ($request, $response, $next) use ($container) {
if ($request->hasHeader('HTTP_X_PJAX')) {
// Here is where I would like to define an arg that can
// be passed down to my views for all requests
}
$response = $next($request, $response);
return $response;
});
@Phunky
Phunky / SassMeister-input-HTML.html
Created October 8, 2015 09:05
Generated by SassMeister.com.
<h1>Example</h1>
<div class="colours"><div class="colour"><div class="base l4">base lighter #4</div><div class="base l3">base lighter #3</div><div class="base l2">base lighter #2</div><div class="base l1">base lighter #1</div><div class="base">base</div><div class="base d1">base darker #1</div><div class="base d2">base darker #2</div><div class="base d3">base darker #3</div><div class="base d4">base darker #4</div></div><div class="colour"><div class="mobilleo l4">mobilleo lighter #4</div><div class="mobilleo l3">mobilleo lighter #3</div><div class="mobilleo l2">mobilleo lighter #2</div><div class="mobilleo l1">mobilleo lighter #1</div><div class="mobilleo">mobilleo</div><div class="mobilleo d1">mobilleo darker #1</div><div class="mobilleo d2">mobilleo darker #2</div><div class="mobilleo d3">mobilleo darker #3</div><div class="mobilleo d4">mobilleo darker #4</div></div><div class="colour"><div class="x l4">x lighter #4</div><div class="x l3">x lighter #3</div><div class="x l2">x lighter #2</div><div class="x
@Phunky
Phunky / app.js
Created November 16, 2015 08:53
Error when trying to use scoped styles with vuejs and node-sass
var Vue = require('vue');
var App = require('../../components/app.vue');
new Vue(App).$mount('#app')