I hereby claim:
- I am voltrevo on github.
- I am voltrevo (https://keybase.io/voltrevo) on keybase.
- I have a public key ASBi6AfkwLtxJNhhHWo0HtCatNDoo3i5Fx7_Nzn1xSXbKgo
To claim this, I am signing this object:
<!DOCTYPE html> | |
<html> | |
<head> | |
<title>Hello World!</title> | |
</head> | |
<body> | |
Hello World! | |
</body> | |
</html> |
I hereby claim:
To claim this, I am signing this object:
'use strict'; | |
(async () => { | |
const stream = await navigator.mediaDevices.getUserMedia({ video: true, audio: true }); | |
const vid = document.createElement('video'); | |
vid.srcObject = stream; | |
document.body.appendChild(vid); | |
vid.style.position = 'absolute'; | |
vid.style.left = '0px'; |
'use strict'; | |
(async () => { | |
const stream = await navigator.mediaDevices.getUserMedia({ video: true }); | |
const vid = document.createElement('video'); | |
vid.srcObject = stream; | |
document.body.appendChild(vid); | |
vid.style.position = 'absolute'; | |
vid.style.left = '0px'; | |
vid.style.top = '0px'; |
/------------------------------------------------------------------------------------------------------------\ | |
| high isolation | partial isolation / uses part of the system | uses the full system | | |
|------------------------+----------------------------------------------------+------------------------------| | |
| | | | | |
| | Not unit tests, so they're integration tests? | | | |
| DEFINITELY | Not integration tests, so they're unit tests? | DEFINITELY | | |
| UNIT TESTS | Maybe these tests are forbidden? | INTEGRATION TESTS | | |
| | Maybe these tests aren't useful? | | | |
| | Or maybe they're not possible? | | | |
| |
'use strict'; | |
export default function mapcat(elements, fn) { | |
return (function* () { | |
for (const el of elements) { | |
for (const newEl of fn(el)) { | |
yield newEl; | |
} | |
} | |
})(); |
(async function() { | |
let headHTML = document.head.innerHTML; | |
await Promise.all( | |
Array.from(document.head.querySelectorAll('link[rel=stylesheet]')) | |
.map(el => fetch(el.href) | |
.then(res => res.text()) | |
.then((cssTxt) => { | |
headHTML += `<style>\n${cssTxt}\n</style>`; | |
}) |
'use strict'; | |
// type Item = { | |
// // Default: 1 | |
// preferenceWeight: number; | |
// | |
// // Should be initialized with preferenceWeight | |
// weight: number; | |
// }; | |
// |
'use strict'; | |
document.head.innerHTML = ''; | |
document.body.innerHTML = ''; | |
[0, 1].forEach((i) => { | |
const iframe = document.createElement('iframe'); | |
iframe.src = location.href; | |
iframe.style.position = 'fixed'; | |
iframe.style.left = (i === 0 ? '0' : '50vw'); |