Skip to content

Instantly share code, notes, and snippets.

View svassr's full-sized avatar

Stéphane Vasseur svassr

  • Noème inc.
  • Montréal
View GitHub Profile
// create a bookmark and use this code as the URL, you can now toggle the css on/off
// thanks+credit: https://dev.to/gajus/my-favorite-css-hack-32g3
javascript: (function() {
var styleEl = document.getElementById('css-layout-hack');
if (styleEl) {
styleEl.remove();
return;
}
styleEl = document.createElement('style');
styleEl.id = 'css-layout-hack';
@svassr
svassr / no-blend.js
Created October 25, 2015 16:52 — forked from mhulse/no-blend.js
A simple JS check to see if CSS mix-blend-mode is supported.
<!doctype html>
<html class="no-blend">
<head>
<script>/* Put no-blend.js code here, sooner rather than later. */</script>
</head>
<body>
...
</body>
</html>
@svassr
svassr / osx_setup.md
Last active August 29, 2015 14:16 — forked from ruyadorno/osx_setup.md

Setup Mac OS X

This is just a personal script to help me remember all the steps required to setup a new osx machine in their correct order. I do not advise you to follow this guide if you don't know what you're doing.

Setup

1. Run software update

function getModernViewport() {
var w = Math.max(document.documentElement.clientWidth, window.innerWidth || 0);
var h = Math.max(document.documentElement.clientHeight, window.innerHeight || 0);
}
function getViewport() {
var viewPortWidth;
var viewPortHeight;