Skip to content

Instantly share code, notes, and snippets.

Avatar
🦄

Sia siakaramalegos

🦄
View GitHub Profile
View nodefest_timetable.md

Timetable

当日のタイムテーブル

11/24

Speakers's dinner 🔈

when where who what
19:30 Shibuya? Staff + Speaker + Sponsers Dinner
@eriktrautman
eriktrautman / sublime_text_2_preferences
Last active Jan 12, 2018
Sublime Text 2 User Preferences
View sublime_text_2_preferences
// These settings can be found under Sublime Text 2 >> Preferences >> Settings - User
// You can just copy-paste this file right over whatever was there if you want
//
// Check out the file at Sublime Text 2 >> Preferences >> Settings - Default
// to see what options are available for you
{
"color_scheme": "Packages/Color Scheme - Default/LAZY.tmTheme",
"font_size": 14.0,
"ignored_packages":
@BideoWego
BideoWego / Searchable.rb
Last active Jul 9, 2018
Model Searchable concern for Rails
View Searchable.rb
module Searchable
def self.included(base)
base.extend(ClassMethods)
end
module ClassMethods
@@searchable_fields = []
@@searchable_scope = nil
def search(q, method=nil)
View pixl-js-party-parrot.js
const frames = [
{
width: 89,
height: 64,
bpp: 1,
transparent: 0,
buffer: E.toArrayBuffer(
atob(
'AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACAwAAAAAAAAAAAAgAEAAAAAAAAAAAMAABAAAAAAAAAABAAABAAAAAAAAAAMB/+AgAAAAAAAAAgf//ggAAAAAAAACD///wgAAAAAAAAIf///wgAAAAAAAAh4///xAAAAAAAACHg/w/BAAAAAAAAIfB+AcCAAAAAAAAB+B4AYCAAAAAAABH8HwAQEAAAAAAAAP4HDwwAAAAAAAAI/weLRyIAAAAAAAR/w4fh+IAAAAAABH//w/j8QAAAAAACP//j/H8AAAAAAAEf//H+P4gAAAAAAB//+P8PwAAAAAAAD//8f4fwAAAAAABH//4/w/iAAAAAACP//w/j/EAAAAAAI///h/H+AAAAAAAR///j+P8AAAAAAAH///H8f4AAAAAACP//+Hw/wAAAAAAAf//8Lj/gAAAAAAR///8KH/EAAAAAAD///4cf+IAAAAACH///4Q/8AAAAAAAP///4D/xAAAAAAQP///wH/iAAAAABAf///wf/AAAAAAAI////w/8AAAAAAIw////j/4gAAAAAjx////n/wAAAAACHh//////EAAAAAIfh/////+IAAAAAh/h/////8AAAAACH/h/////xAAAAAMf/h/////iAAAAAR//g/////AAAAABH//gP///8QAAAAEP//wB///4gAAAAQ///4D///xAAAABD///+H///iAAAAEP////////EAAAAQ////////+IAAABD////////+QAAAEP////////8AAAAQ/////////4gAAAj/////////xAAACP/////////iAAAEf/////////gAA
@rviscomi
rviscomi / CrashCourseInCrUX.md
Last active May 7, 2019
"Crash Course in CrUX" for the PerfMatters conference, April 2019
View CrashCourseInCrUX.md
@mperham
mperham / after.rb
Created Jul 4, 2012
Thread-friendly shared connection
View after.rb
class ActiveRecord::Base
mattr_accessor :shared_connection
@@shared_connection = nil
def self.connection
@@shared_connection || ConnectionPool::Wrapper.new(:size => 1) { retrieve_connection }
end
end
ActiveRecord::Base.shared_connection = ActiveRecord::Base.connection
@jacob-beltran
jacob-beltran / requestAnimationFrame.js
Last active Apr 17, 2020
React Performance: requestAnimationFrame Example
View requestAnimationFrame.js
// How to ensure that our animation loop ends on component unount
componentDidMount() {
this.startLoop();
}
componentWillUnmount() {
this.stopLoop();
}
@Aidurber
Aidurber / cleanup.sh
Last active Jul 1, 2020
A handy script to clean up a mac thanks to - Gant Laborde's article: https://medium.freecodecamp.org/how-to-free-up-space-on-your-developer-mac-f542f66ddfb
View cleanup.sh
# Cleanup old node_modules
echo "Cleaning node_modules in projects older than 30 days"
find . -name "node_modules" -type d -mtime +30 | xargs rm -rf
echo "Done cleaning node_modules"
# Clean up homebrew
echo "Clean homebrew"
brew update && brew upgrade && brew cleanup
echo "Done cleaning homebrew"
@cferdinandi
cferdinandi / markdown-editor.html
Last active Apr 19, 2021
A vanilla JS version of the example markdown editor app for Vue.js. https://vuejs.org/v2/examples/
View markdown-editor.html
<!DOCTYPE html>
<html>
<head>
<title>Marked Demo</title>
<style type="text/css">
body {
margin: 0 auto;
height: 100%;
font-family: 'Helvetica Neue', Arial, sans-serif;
color: #333;
@jwill
jwill / MemeMaker.html
Last active Jul 15, 2021
Starter code for Meme Maker
View MemeMaker.html
<!DOCTYPE html>
<html>
<head>
<title>MemeMaker-Simple</title>
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0">
<meta name="mobile-web-app-capable" content="yes">
<meta name="apple-mobile-web-app-capable" content="yes">
<style>