Skip to content

Instantly share code, notes, and snippets.

/* This is a small sampling of the various approaches to media queries. The
point is: they're all over the board. Part of the "issue" (if you can call
it that) may be due to the intended audience of each site/framework. Another
may be that it's really difficult to test for a lot of different devices.
Regardless, it would be really nice if there was standard baseline that
could be used as a starting point for maximum compatibility and coverage. */
/* ==========================================================================
Frameworks
========================================================================== */
@Alex-Werner
Alex-Werner / high-dpi-media.css
Created November 16, 2016 17:38 — forked from wylieconlon/high-dpi-media.css
A CSS media query that captures almost all high DPI aware devices.
/* -------------------------------------------------------- */
/* */
/* A media query that captures: */
/* */
/* - Retina iOS devices */
/* - Retina Macs running Safari */
/* - High DPI Windows PCs running IE 8 and above */
/* - Low DPI Windows PCs with IE zoomed in */
/* - Android hdpi devices and above */
/* - Android tvdpi devices, including Google Nexus 7 */

Keybase proof

I hereby claim:

  • I am Alex-Werner on github.
  • I am awerner (https://keybase.io/awerner) on keybase.
  • I have a public key whose fingerprint is 2193 DFAD D4AA B54D B23F 341C B7CF 5A35 5467 C1B2

To claim this, I am signing this object:

function parseCookies(cookie) {
return cookie.split(';').reduce(
function(prev, curr) {
var m = / *([^=]+)=(.*)/.exec(curr);
var key = m[1];
var value = decodeURIComponent(m[2]);
prev[key] = value;
return prev;
},
{ }
//Hapi JS use his own cypher algorithm
//see here : https://github.com/hueniverse/iron
handler:funcition(request, reply){
var ssid = req.headers['cookie'].split('session=')[1];
var sidPassword = request.connection.states.cookies.session.password
Iron.unseal(ssid,,Iron.defaults, function (err, unsealed) {
console.log(unsealed);
});
}
@Alex-Werner
Alex-Werner / debug.html
Created December 26, 2015 10:57
ChainedPromise Angular
<!--https://github.com/mohsen1/json-formatter -->
<link href="scripts/vendor/json-formatter.min.css" rel="stylesheet" type="text/css">
<div class="container">
<div class="jumbotron">
<h1>Test interface</h1>
<p>Total progression :
<div id="totalProgression" class="progress"></div>
<button type="button" class="btn btn-lg btn-danger" ng-click="runAllTest()">Run All</button>
@Alex-Werner
Alex-Werner / gist:10981495
Last active August 29, 2015 13:59
Wall ? Why ?
J'ai mal lu la question posé sur Reddit, mais au cas ou un autre repose la quesiton, à réutiliser à ce moment la.
----
There are so many reason explaining that.
Some people do that for, well, not manipulation, but like suggestion.
Imagine, price is at 510. You set a buy order of 10 000BTC @500.
Then price will likely go up, because imagine now a guy who want to sell @510, he see the big wall order, he can think (predict ? Mistake ?) that price won't go under 500. So he will hold and may be buy (when at the first time he wanted to sell).