This file contains hidden or 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
<aside> | |
<dark-mode-toggle | |
id="dark-mode-toggle" | |
legend="Theme Switcher" | |
light="Light" | |
dark="Dark" | |
appearance="switch" | |
permanent="false" | |
></dark-mode-toggle> | |
</aside> |
This file contains hidden or 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="en"> | |
<head> | |
<link rel="stylesheet" href="common.css" /> | |
<link | |
rel="stylesheet" | |
href="light.css" | |
media="(prefers-color-scheme: light), (prefers-color-scheme: no-preference)" | |
/> | |
<link |
This file contains hidden or 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="en"> | |
<head> | |
<meta charset="UTF-8"> | |
<meta name="viewport" content="width=device-width, initial-scale=1.0"> | |
<meta http-equiv="X-UA-Compatible" content="ie=edge"> | |
<title>Toggle</title> | |
</head> | |
<body> | |
This file contains hidden or 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
<div class="ui three buttons"> | |
<button class="ui active button">One</button> | |
<button class="ui button">Two</button> | |
<button class="ui button">Three</button> | |
</div> |
This file contains hidden or 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 IPFS = require('ipfs') | |
async function main () { | |
const node = await IPFS.create({silent: true}) | |
const filesAdded = await node.add({ | |
path: 'hello.txt', | |
content: Buffer.from('Hello World 101') | |
}) |
This file contains hidden or 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 IPFS = require('ipfs') | |
async function main () { | |
const node = await IPFS.create() | |
} | |
main() |
This file contains hidden or 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 IPFS = require('ipfs') | |
async function main () { | |
const node = await IPFS.create() | |
} | |
main() |
This file contains hidden or 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 IPFS = require('ipfs') | |
const main = async () => { | |
// place ipfs logic here | |
} | |
main() |
This file contains hidden or 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
class Counter extends HTMLElement { | |
#xValue = 0; | |
get #x() { return #xValue; } | |
set #x(value) { | |
this.#xValue = value; | |
window.requestAnimationFrame(this.#render.bind(this)); | |
} | |
#clicked() { |
This file contains hidden or 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
class Counter extends HTMLElement { | |
#x = 0; | |
clicked = () => { | |
this.#x++; | |
window.requestAnimationFrame(this); | |
} | |
constructor() { | |
super(); |