Skip to content

Instantly share code, notes, and snippets.

View gwenf's full-sized avatar

Gwendolyn Faraday gwenf

View GitHub Profile
title minutes views
React State Management (P5D58) - Live Coding with Jesse 8 826
React Infinite Scroll (P5D57) - Live Coding with Jesse 23 1166
Working with React Components Part 2 (P5D56) - Live Coding with Jesse 19 726
Coding for a Swedish Startup - a day in the life of Amber Wilkie 9 2744
Working with React Components (P5D55) - Live Coding with Jesse 2 1162
Basic CSS Styling Part 2 (P5D54) - Live Coding with Jesse 45 1704
Writing Secure JavaScript 24 3265
Learn HTML5 - full course with code samples 52 11540
Basic CSS Styling (P5D53) - Live Coding with Jesse 39 2522
@dylanmckay
dylanmckay / facebook-contact-info-summary.rb
Last active March 12, 2024 22:46
A Ruby script for collecting phone record statistics from a Facebook user data dump
#! /usr/bin/env ruby
# NOTE: Requires Ruby 2.1 or greater.
# This script can be used to parse and dump the information from
# the 'html/contact_info.htm' file in a Facebook user data ZIP download.
#
# It prints all cell phone call + SMS message + MMS records, plus a summary of each.
#
# It also dumps all of the records into CSV files inside a 'CSV' folder, that is created
@arpit
arpit / cryptokitties.sol
Created January 23, 2018 21:33
Cryptokitties Contract from the Eth blockchain
pragma solidity ^0.4.11;
/**
* @title Ownable
* @dev The Ownable contract has an owner address, and provides basic authorization control
* functions, this simplifies the implementation of "user permissions".
*/
contract Ownable {
address public owner;
@geoffreydhuyvetters
geoffreydhuyvetters / react_fiber.md
Last active January 13, 2023 06:49
What is React Fiber? And how can I try it out today?
componentWillReceiveProps(nextProps) {
if (nextProps.lastRequestedUserLocationAt > this.props.lastRequestedUserLocationAt) {
this.centerMapToUser(nextProps.currentLocation);
}
if (nextProps.lastUpdated > this.props.lastUpdated) {
const markers = this.createMarkersForLocations(nextProps);
if (markers && Object.keys(markers)) {
const clusters = {};
@terranware
terranware / snsToSlack.js
Last active March 7, 2024 14:47
AWS Lambda function to Slack Channel hookup
var https = require('https');
var util = require('util');
exports.handler = function(event, context) {
console.log(JSON.stringify(event, null, 2));
console.log('From SNS:', event.Records[0].Sns.Message);
var postData = {
"channel": "#aws-sns",
"username": "AWS SNS via Lamda :: DevQa Cloud",
@Tritlo
Tritlo / TailRec.hy
Last active October 4, 2022 13:55
Proper Tail Recursion in Python
(defclass TailCall [Exception]
"An exeception to implement Proper Tail Recursion"
[[--init--
(fn [self __TCFunc &rest args &kwargs kwargs]
(setv self.func __TCFunc)
(setv self.args args)
(setv self.kwargs kwargs)
nil)]])
(defn TailRec [func]
@eguneys
eguneys / gesture.js
Created August 31, 2014 11:37
A Gesture Manager for Phaser.
'use strict';
define(['phaser'], function(Phaser) {
function Gesture(game) {
this.game = game;
this.swipeDispatched = false;
this.holdDispatched = false;
this.isTouching = false;
@staltz
staltz / introrx.md
Last active May 23, 2024 20:07
The introduction to Reactive Programming you've been missing
@pinceladasdaweb
pinceladasdaweb / imgur.js
Created March 27, 2014 13:14
Upload images to imgur via JavaScript
/*
--------------------------------
imgur Upload
--------------------------------
+ https://github.com/pinceladasdaweb/imgur-upload
+ version 1.1
+ Copyright 2014 Pedro Rogerio
+ Licensed under the MIT license
+ Documentation: https://github.com/pinceladasdaweb/imgur-upload