This file contains hidden or 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
# credit: http://haacked.com/archive/2014/07/28/github-flow-aliases/ | |
[user] | |
name = Halil Kayer | |
email = [email protected] | |
signingkey = 60C52C88E94A6EB1 | |
[core] | |
editor = micro | |
pager = delta | |
excludesfiles = /Users/u132515/.gitignore | |
[commit] |
This file contains hidden or 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
"questions": [ | |
{ | |
"question_type": "multiple-choice", | |
"identifier": "ac9835eb-9efa-4cce-9e35-09987d32e6c8", | |
"headline": "Multiple Choice Question Sentence 1", | |
"description": null, | |
"required": false, | |
"multiple": true, | |
"choices": [ | |
{ |
This file contains hidden or 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
var HashTable = function() { | |
this._storage = []; | |
this._count = 0; | |
this._limit = 8; | |
} | |
HashTable.prototype.insert = function(key, value) { | |
//create an index for our storage location by passing it through our hashing function | |
var index = this.hashFunc(key, this._limit); |
This file contains hidden or 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
/** | |
* Demo: http://vpalos.com/sandbox/filter.js/ | |
* | |
* A generic search algorithm designed for filtering (very) large lists of strings; when an input string | |
* contains all the parts (words or characters; whitespace is ignored) of the query, spread-out over the text | |
* then the string is considered to be a match. It works with the way internet browsers (e.g. Firefox, Google | |
* Chrome) filter address-bar suggestions on user input. It is also quite fast; on my i7 laptop, filtering | |
* 1) a list of ~23000 items takes around 50ms (yes, milliseconds!); | |
* 2) a list of ~1 million text items took under 1 second. | |
* It works both in NodeJS as well as in browser environments (so far I only tested FF and GC). |
This file contains hidden or 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
<!-- plyr binding usage --> | |
<div class="video-player-container" data-bind="plyr:{videos:playerData.videos,cover:playerData.cover, instance:playerData.instance}"></div> |
This file contains hidden or 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
This is the javascript regular expression to check password meet the reqirements. | |
Here it is : | |
/^(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[$-/ | :-? | {-~ | ! | @ | # | " | ^ | _ |` | \[ | \]])[a-zA-Z0-9$-/:-?{-~!@#"^_`\[\]]{8,16}/g | |
(?=.*[a-z]) means should include lowercase letter | |
(?=.*[A-Z]) means should include uppercase letter | |
(?=.*[0-9]) means should include number | |
(?=.*[$-/ | :-? | {-~ | ! | @ | # | " | ^ | _ |` | \[ | \]]) means should include symbol |
This file contains hidden or 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 (w, d, s) { | |
function go() { | |
var js, | |
fjs = d.getElementsByTagName(s)[0], | |
load = function (url, id) { | |
if (d.getElementById(id)) { return; } | |
js = d.createElement(s); | |
js.src = url; | |
js.id = id; | |
fjs.parentNode.insertBefore(js, fjs); |
This file contains hidden or 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
var myApp = angular.module('myApp', []); | |
myApp.controller('MyCtrl', function ($scope) { | |
$scope.parts = [{"Id":7204, "Name":"Air Cleaner", "ProductCount":3452}, | |
{"Id":7205, "Name":"Battery", "ProductCount":76}, | |
{"Id":7206, "Name":"Choke", "ProductCount":342}, | |
{"Id":7207, "Name":"Clutch Lever", "ProductCount":98}, | |
{"Id":7208, "Name":"Crankcase Cover", "ProductCount":0}, | |
{"Id":7209, "Name":"Crash Bar", "ProductCount":456}, | |
{"Id":7210, "Name":"Cylinder", "ProductCount":184}, |
NewerOlder