Skip to content

Instantly share code, notes, and snippets.

View MoatazAbdAlmageed's full-sized avatar
⌨️
pressing f12 key

Moataz Mohammady MoatazAbdAlmageed

⌨️
pressing f12 key
View GitHub Profile
@mizzao
mizzao / cloudSettings
Last active July 15, 2021 03:11
Visual Studio Code Settings Sync Gist
{"lastUpload":"2021-02-23T20:44:09.529Z","extensionVersion":"v3.4.3"}
@elitan
elitan / ContactForm.js
Last active November 9, 2022 05:21
React Router V4 Redirect after form submission
import React, { Component } from 'react';
import { withRouter } from 'react-router-dom'; // <--- import `withRouter`. We will use this in the bottom of our file.
class ContactForm extends Component {
submitForm (e) {
e.preventDefault()
this.props.history.push('/thank-you'); // <--- The page you want to redirect your user to.
}
@marshyyyy
marshyyyy / BlockYouTubeHostsFile
Created November 18, 2017 05:02
Block YouTube Hosts File
0.0.0.0 host.youtube.com
0.0.0.0 mx.youtube.com
0.0.0.0 admin.youtube.com
0.0.0.0 devel.youtube.com
0.0.0.0 stats.youtube.com
0.0.0.0 http.youtube.com
0.0.0.0 mx0.youtube.com
0.0.0.0 administration.youtube.com
0.0.0.0 development.youtube.com
0.0.0.0 svn.youtube.com
@veiko
veiko / .stylelintrc
Last active July 1, 2019 14:48
Default .stylelintrc file for new projects
{
"rules": {
"at-rule-empty-line-before": [ "always", {
"except": ["blockless-after-same-name-blockless", "first-nested"]
} ],
"at-rule-name-case": "lower",
"at-rule-name-newline-after": "always-multi-line",
"at-rule-name-space-after": "always-single-line",
"at-rule-semicolon-space-before": "never",
"block-no-empty": true,
@jeffochoa
jeffochoa / Response.php
Last active May 18, 2024 13:21
Laravel HTTP status code
<?php
// This can be found in the Symfony\Component\HttpFoundation\Response class
const HTTP_CONTINUE = 100;
const HTTP_SWITCHING_PROTOCOLS = 101;
const HTTP_PROCESSING = 102; // RFC2518
const HTTP_OK = 200;
const HTTP_CREATED = 201;
const HTTP_ACCEPTED = 202;
@agarrharr
agarrharr / index.md
Last active February 18, 2020 09:54
Getting Started with Redux by Dan Abramov Notes

Redux Course

https://egghead.io/courses/getting-started-with-redux

Principles

  1. Single source of truth
    • Describe the state of the entire app in the state
  2. State is read-only
  • The state tree is redundant. You cannot modify it. Everytime you want to change the state, you dispatch an action.
@root-talis
root-talis / php7_build_ubuntu.sh
Created August 21, 2017 06:49 — forked from m1st0/php_build_ubuntu.sh
Compiling PHP 7 on Ubuntu 15.04 with Various Supported Modules
#! /bin/bash
# PHP 7 Initial Compile #
# Author: Maulik Mistry
# Date: Aug 04, 2017
# References:
# http://www.zimuel.it/install-php-7/
# http://www.hashbangcode.com/blog/compiling-and-installing-php7-ubuntu
#
# License: BSD License 2.0
@paulund
paulund / phpcs.xml
Created August 20, 2017 16:50
PHP PSR-2 CodeSniffer Config for Laravel
<?xml version="1.0"?>
<ruleset name="Laravel Standards">
<!--
The name attribute of the ruleset tag is displayed
when running PHP_CodeSniffer with the -v command line
argument. The description tag below is not displayed anywhere
except in this file, so it can contain information for
developers who may change this file in the future.
-->
@humorless
humorless / neovim.md
Last active January 15, 2020 04:38
How to install neovim in Ubuntu-14.04 & using terminal mode

Install neovim in ubuntu 14.04

sudo add-apt-repository ppa:neovim-ppa/unstable 
sudo apt-get update
sudo apt-get install neovim

Using terminal mode

  1. Enter terminal mode
anonymous
anonymous / -
Created May 22, 2017 13:19
System: Host: Toshiba2014-Satellite-L75D-A Kernel: 4.4.0-21-generic x86_64 (64 bit gcc: 5.3.1)
Desktop: Cinnamon 3.2.7 (Gtk 3.18.9-1ubuntu3.3) dm: mdm Distro: Linux Mint 18.1 Serena
Machine: System: TOSHIBA product: Satellite L75D-A v: PSKNJU-004001
Mobo: AMD model: Larne Bios: Insyde v: 1.40 date: 09/12/2013
CPU: Quad core AMD A4-5000 APU with Radeon HD Graphics (-MCP-) cache: 8192 KB
flags: (lm nx sse sse2 sse3 sse4_1 sse4_2 sse4a ssse3 svm) bmips: 11977
clock speeds: min/max: 800/1500 MHz 1: 1300 MHz 2: 800 MHz 3: 1500 MHz 4: 800 MHz
Graphics: Card: Advanced Micro Devices [AMD/ATI] Kabini [Radeon HD 8330]
bus-ID: 00:01.0 chip-ID: 1002:9832
Display Server: X.Org 1.18.3 drivers: ati,radeon (unloaded: fbdev,vesa)