Skip to content

Instantly share code, notes, and snippets.

View eslammahgoub's full-sized avatar

eslam mahgoub eslammahgoub

View GitHub Profile
@eslammahgoub
eslammahgoub / flux.js
Created June 16, 2021 15:25 — forked from acdlite/flux.js
A Redux-like Flux implementation in <75 lines of code
/**
* Basic proof of concept.
* - Hot reloadable
* - Stateless stores
* - Stores and action creators interoperable with Redux.
*/
import React, { Component } from 'react';
export default function dispatch(store, atom, action) {
@eslammahgoub
eslammahgoub / AuthHttp.ts
Created May 18, 2017 16:26 — forked from chandermani/AuthHttp.ts
Angular 2, Http service wrapper to pass authorization token with each request.
import {Injectable, EventEmitter} from 'angular2/core';
import {Http, Headers, RequestOptions, RequestOptionsArgs, Response, RequestMethod, Request, Connection, ConnectionBackend} from 'angular2/http';
import * as Rx from 'rxjs';
export enum Action { QueryStart, QueryStop };
@Injectable()
export class AuthHttp {
process: EventEmitter<any> = new EventEmitter<any>();
@eslammahgoub
eslammahgoub / Rot13
Created September 17, 2013 01:09
Creating ( In Python ) a fully working google apps engine Rot13. it's a web page that lets you Rot13 some text in a form it's look like this it's make some alogrithm to text hello --> uryyb and inverse uryyb --> hello you can try it enjoy :) Anyone that needed help on Udacity can look here.
import webapp2
import cgi
form = """
<form method="post" id="form_id">
<p><h2> Enter some Text to ROT13 : </h2></p>
<textarea name="word" cols="60" rows="10" form="form_id">%(word)s</textarea>
<br>
<label>Month <input type="text" name="month" value="%(month)s">
</label>