Skip to content

Instantly share code, notes, and snippets.

View gorhgorh's full-sized avatar

Jérôme Zhang gorhgorh

View GitHub Profile
@gorhgorh
gorhgorh / modernizr_leap.js
Last active August 29, 2015 13:55
test to see if a leapD deamon is running
Modernizr.addTest('leap', function(){
var leapSupport;
// function test leapDeamon presence
function checkLeap() {
// create a websocket to the lead daemon
// i maybe i should just test that, bot something else could provide a webosket here ?
var ws = new WebSocket("ws://localhost:6437/");
// if there is one i( provide the event on open
/* jshint forin:true, noarg:true, noempty:true, eqeqeq:true, bitwise:true,
* strict:true, undef:true, curly:true, browser:true, indent:2, maxerr:50
*/
/*
* Note: use http://www.jshint.com/ to validate your code and make sure it
* doesn't catch any bad practices or error prone programming, also it may
* be handy to leave the options you validated your code with at the top
* of the file so it can be easiy validated later
*/
.DS_Store
.AppleDouble
.LSOverride
Icon
# Thumbnails
._*
# Files that might appear on external disk