Last active
January 26, 2021 15:54
-
-
Save ckerr/7985be12498d49847bc2055723ecee1e to your computer and use it in GitHub Desktop.
@simann's testcase for https://github.com/electron/electron/issues/26714
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html lang="de"> | |
<head> | |
<meta charset="utf-8" /> | |
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0"> | |
</head> | |
<body> | |
<!-- note: this is just a random test pdf. | |
the test behaves the same with local files, but gist.github.com doesn't seem to like to store pdf files --> | |
<embed src="http://www.episcenter.psu.edu/sites/default/files/Presentations/empty.pdf" style="width:100%;height:400px"> | |
</body> | |
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const { app, BrowserWindow, session } = require('electron'); | |
const { join } = require('path'); | |
// uncomment this line to break the PDF Viewer | |
//app.commandLine.appendSwitch('disable-site-isolation-trials'); | |
async function ready() { | |
const mainWindow = new BrowserWindow({ | |
x: 0, | |
y: 0, | |
width: 800, | |
height: 800, | |
show: true, | |
}); | |
mainWindow.loadURL(join("file://", __dirname, "main.html")); | |
} | |
app.whenReady().then(ready); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"name": "electron-quick-start", | |
"version": "1.0.0", | |
"description": "A minimal Electron application", | |
"main": "main.js", | |
"scripts": { | |
"start": "electron .", | |
"start2": "electron --disable-site-isolation-trials ." | |
}, | |
"repository": "https://github.com/electron/electron-quick-start", | |
"keywords": [ | |
"Electron", | |
"quick", | |
"start", | |
"tutorial", | |
"demo" | |
], | |
"author": "GitHub", | |
"license": "CC0-1.0", | |
"devDependencies": { | |
"electron": "^11.0.0" | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment