This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React from 'react'; | |
const Fragment = React.Fragment; | |
const person = (props) => { | |
return ( | |
<Fragment> | |
<p>Name: {props.name}.</p> | |
<p>Age: {props.age}</p> | |
</Fragment> | |
); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/data/data/com.termux/files/usr/bin/bash | |
# 4/05/2017 Gabi Tiplea | |
echo -e "Updating default packages\n" | |
apt update && apt -y upgrade | |
echo -e "Requesting acces to storage\n" | |
termux-setup-storage | |
sleep 5 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function isUnique (str) { | |
for (let i = 0; i < str.length; i++) { | |
let tmp1 = str[i]; | |
for (let j = i; j < str.length; j++) { | |
if (i == j) { | |
continue; | |
} | |
let tmp2 = str[j]; | |
if (tmp1 === tmp2) { | |
return false |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// directive JS | |
(function() { | |
'use strict'; | |
angular | |
.module('app') | |
.directive('oneWayBind', oneWayBind); | |
oneWayBind.$inject = []; | |
function oneWayBind() { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Laravel 5.4 From Scratch: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# PHP framework and composer files | |
vendor | |
# sublime editor files | |
*.sublime* | |
SideBarEnhancements.json |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
export PS1='\W$(__git_ps1 "(%s)") > ' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[user] | |
name = Sheryar Shirazi | |
email = sheryarshirazi@gmail.com | |
[core] | |
editor = 'c:/program files/sublime text 3/subl.exe' -w | |
excludesfile = c:/Users/sheryar shirazi/.gitignore_global | |
[alias] | |
st = status | |
co = checkout | |
ci = commit |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Windows image file caches | |
Thumbs.db | |
# Folder config file | |
Desktop.ini | |
# Recycle.Bin used on files shares | |
$RECYCLE.BIN/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php namespace yourName; | |
/** | |
* return constant array key | |
* @param constant $const constant array name | |
* @param int $index index of constant array key value (in my case its int) | |
* @return string key name (string in my case) | |
*/ | |
function getConstantArrayNames($const, $index) { | |
$x = get_defined_constants(true); |
NewerOlder