Skip to content

Instantly share code, notes, and snippets.

@zsalzbank
Created July 21, 2015 17:29
Show Gist options
  • Save zsalzbank/5b8eb32ad9f8fd33dc0f to your computer and use it in GitHub Desktop.
Save zsalzbank/5b8eb32ad9f8fd33dc0f to your computer and use it in GitHub Desktop.
no partial content for intercept
<html>
<head>
</head>
<body>
<video autoplay loop>
<source src="http://html5demos.com/assets/dizzy.mp4" type="video/mp4">
</video>
</body>
</html>
var app = require('app'),
BrowserWindow = require('browser-window');
var mainWindow = null;
app.on('window-all-closed', app.quit);
app.on('ready', function() {
mainWindow = new BrowserWindow({
width: 800,
height: 600
});
var protocol = require('protocol');
protocol.interceptProtocol('http', function(){}, function(){
mainWindow.loadUrl('file:///' + __dirname + '/index.htm');
mainWindow.openDevTools({detach: true});
});
protocol.registerStandardSchemes(['http']);
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment