Skip to content

Instantly share code, notes, and snippets.

Jeff Tchang tachang

Block or report user

Report or block tachang

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@markerikson
markerikson / ReactControlledInputWithState.jsx
Created Aug 2, 2017
React controlled input with internal state example
View ReactControlledInputWithState.jsx
class ControlledInputWithInternalState extends Component {
constructor(props) {
super(props);
this.state = {
isValid : true,
value : props.value
};
}
@itsmemattchung
itsmemattchung / Makefile
Last active Jul 3, 2019
Makefile example for aws lambda
View Makefile
PROJECT = sample-python-app
FUNCTION = $(PROJECT)
REGION = us-east-1
.phony: clean
clean:
rm -f -r $(FUNCTION)*
rm -f -r site-packages
@vero4karu
vero4karu / tests.py
Last active Aug 22, 2019
Mock/replace timezone.now() with a custom date in Django unittes
View tests.py
#! /usr/bin/env python
# -*- coding: utf-8 -*-
import datetime
from mock import patch
from django.test import TestCase
from django.utils import timezone
class DatesTestCase(TestCase):
@dfwarden
dfwarden / gapps-groupssettings-adminexample.py
Created Apr 30, 2013
Example of administrative OAuth 2.0 access to Google Group Settings API.
View gapps-groupssettings-adminexample.py
import httplib2
import oauth2client.client
import pprint
from apiclient.discovery import build
serviceacct_email = "<your service account email address>"
f = file('groupssettings-privatekey.p12', 'rb')
client_key = f.read()
f.close()
You can’t perform that action at this time.