Skip to content

Instantly share code, notes, and snippets.

@marcel12bell
marcel12bell / gist:de5877482ccfe6859dbf
Created March 14, 2015 15:47
noble/issues/141 related
----- services.js -----
var noble = require('../index');
noble.on('stateChange', function(state) {
if (state === 'poweredOn') {
noble.startScanning();
} else {
noble.stopScanning();
}
});
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<meta http-equiv="X-UA-Compatible" content="chrome=1">
<meta name="apple-mobile-web-app-capable" content="yes" />
<meta name="apple-mobile-web-app-status-bar-style" content="black-translucent" />