Skip to content

Instantly share code, notes, and snippets.

View graphoarty's full-sized avatar
🎯
Focusing

Quinston Pimenta graphoarty

🎯
Focusing
  • https://quinston.com
  • Pune, India
View GitHub Profile
{
...,
...,
"scripts": {
...,
"start": "node main.js"
},
...,
...
}
{
...,
...,
"scripts": {
...,
"start": "node ."
},
...,
...
}
git add .
git commit -m "Initial Commit"
git push -u origin master
const { app, BrowserWindow } = require('electron');
{
...,
...,
"scripts": {
...,
"start": "electron ."
},
...,
...
}
// main.js
// Import app and BrowserWindow
const { app, BrowserWindow } = require('electron');
// When Electron has finished initializing after import, run the window creation function
app.on('ready', function(){
// Browser window actually creates the window (Create and control browser windows.)
win = new BrowserWindow({ width: 1280, height: 720 });
<!-- index.js -->
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>360 / VR Viewer</title>
</head>
<body>
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>360 / VR Viewer</title>
<!-- Compiled and minified CSS -->
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/materialize/1.0.0/css/materialize.min.css">
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>360 / VR Viewer</title>
<link rel="stylesheet" href="./css/materialize.min.css">
<!-- Three.js will use this div as the viewport (on our request of course) -->
<div id="webglviewer" class="full-screen"></div>