Skip to content

Instantly share code, notes, and snippets.

Origin1 Tech origin1tech

  • Origin1 Tech
Block or report user

Report or block origin1tech

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
@origin1tech
origin1tech / uid.ts
Last active Jun 11, 2019
JavaScript Firebase UID Generation
View uid.ts
export interface IUID {
generate(): string;
timestamp(uid: string, asDate?: boolean): number | Date;
}
/**
* SEE --> https://gist.github.com/mikelehen/3596a30bd69384624c11
*
@origin1tech
origin1tech / oauthredirect.js
Created Oct 8, 2015
Firebase OAuth Redirect
View oauthredirect.js
// Custom connection class to obtain root conneciton.
var conn = new FirebaseConnection('auchat');
// conn returns the connection class instance
// of which contains a property called "root"
// which is the Firebase root ref.
conn.root.onAuth(function(authData) {
if (authData !== null) {
console.log("Authenticated successfully with payload:", authData);
You can’t perform that action at this time.