Skip to content

Instantly share code, notes, and snippets.

View darcyclarke's full-sized avatar
🔥
busy building things...

Darcy Clarke darcyclarke

🔥
busy building things...
View GitHub Profile
@darcyclarke
darcyclarke / pubsub.js
Last active September 17, 2016 17:39
Library agnostic publish/subscribe
/*!
*
* Library Agnostic Pubsub
* http://darcyclarke.me/articles/development/library-agnostic-pubsub-publish-subscribe/
*
* Copyright 2016, Darcy Clarke
* Do what you want license...
*
*/
(function(window){
@darcyclarke
darcyclarke / strip.php
Last active May 27, 2016 03:09
Strip text out from between two strings
<?php
/***********************************************/
/* PHP Strip Function
/* http://darcyclarke.me/articles/development/strip-out-text-between-two-tags-in-a-string-php/
/*
/* Copyright 2016, Darcy Clarke
/* Do what you want license
/***********************************************/
function strip($startTag,$endTag,$text,$pos=0){
if(!is_integer($pos)){
@darcyclarke
darcyclarke / clean.js
Created May 27, 2016 03:04
Get Clean window & DOM Objects
/*!
*
* Get Clean window & DOM Objects
* http://darcyclarke.me/articles/development/getting-a-clean-document-or-window-object-in-javascript/
*
* Copyright 2016, Darcy Clarke
* Do what you want license
*
*/
(function(){
@darcyclarke
darcyclarke / gulpfile.coffee
Created May 29, 2015 13:30
Example Build file
# --------------------------------------
# Setup
# --------------------------------------
server = false
fs = require( 'fs' )
path = require( 'path' )
_ = require( 'underscore' )
wrench = require( 'wrench' )