Skip to content

Instantly share code, notes, and snippets.

View kyleschmolze's full-sized avatar

Kyle Schmolze kyleschmolze

View GitHub Profile

Keybase proof

I hereby claim:

  • I am kyleschmolze on github.
  • I am kyleschmolze (https://keybase.io/kyleschmolze) on keybase.
  • I have a public key ASCLj-rOGJxpbAYpcYN-golqn5kBSyyhK3CEDTPWWRjmpgo

To claim this, I am signing this object:

###
This super simple script loads SlimFAQ content into any page.
Specify a category from SlimFAQ by it's URL, and put a simple
template into the HTML, and this script will auto-load those questions
into the page. When clicked, the links will open inside the SlimFAQ sidebar.
Sample html template:
<div data-slimfaq-category='http://faq.groupmuse.com/323-hosting' data-slimfaq-limit=2>
<h2 data-slimfaq-category-name></h2>
<p data-slimfaq-question-template></p>
# Another attempt using the built in Rails.cache.fetch (better serialization/deserialization)
class ActiveSupport::Cache::DalliStore
def fast_fetch(name, options=nil)
options ||= {}
name = expanded_key name
dupe_name = name+'_dupe'
if block_given?
unless options[:force]
@kyleschmolze
kyleschmolze / makehub
Created August 3, 2015 01:02
Groupmuse
# Title
Groupmuse
# Picture
media: undefined
# Objective
undefined
# Duration
undefined
# Age Group
undefined
@kyleschmolze
kyleschmolze / db.coffee
Created March 17, 2015 13:54
Simple Angular Database - JSON in LocalStorage as a service
###
This dead-simple service just returns a javascript object called "Db",
which comes with two functions built in: save() and clear().
Save attributes directly onto the object, then call Db.save(), and it
will be written into localstorage.
Sample usage:
angular.module("my_app").controller "HomeCtrl", (Db) ->
$scope.user = Db.user || {};
@kyleschmolze
kyleschmolze / back_button_manager.coffee
Created December 10, 2014 20:42
Easy back button service for Ionic on Android
# I wanted to be able to easily add back button callbacks to certain app states
# (using the word "state" here in the context of ui-router).
# For example, I always know that the back button on page X should quit the app, etc.
# So I wrote this nifty service.
angular.module("groupmuse").service "BackButtonManager", ($rootScope, $ionicPlatform) ->
managedStates = []
$rootScope.$on '$stateChangeSuccess', (event, next) ->
# Disable all listeners
@kyleschmolze
kyleschmolze / index.html
Created October 8, 2014 22:46
A Pen by Kyle Nichols-Schmolze.
<div class='container'>
<img src='http://bit.ly/catzzzzzz' />
<p>
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
<br>
<br>
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
</p>
</div>
@kyleschmolze
kyleschmolze / index.html
Created October 8, 2014 22:42
A Pen by Kyle Nichols-Schmolze.
<nav>
<a href='/'>Link 1</a>
<a href='/'>Link 2</a>
<a href='/'>Link 3</a>
<a href='/'>Link 4</a>
<a href='/'>Link 5</a>
</nav>
@kyleschmolze
kyleschmolze / index.html
Created October 8, 2014 22:42
A Pen by Kyle Nichols-Schmolze.
<nav>
<a href='/'>Link 1</a>
<a href='/'>Link 2</a>
<a href='/'>Link 3</a>
<a href='/'>Link 4</a>
<a href='/'>Link 5</a>
</nav>
@kyleschmolze
kyleschmolze / index.html
Last active August 29, 2015 14:07
A Pen by Kyle Nichols-Schmolze.
<p>
We heard you like
<a href='/'>Links</a>,
so we put a
<a href='/'>Link</a>
in yo
<a href='/'>Link</a>
so you can
<a href='/'>Link</a>
while you