mirror of
https://github.com/Sneed-Group/frontend-js-example
synced 2024-12-23 11:42:51 -06:00
Update 'index.html'
This commit is contained in:
parent
dfe4324ccd
commit
d3165a202b
1 changed files with 15 additions and 7 deletions
20
index.html
20
index.html
|
@ -1,18 +1,26 @@
|
||||||
|
|
||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html>
|
<html>
|
||||||
<head>
|
<head>
|
||||||
<title>FrontendJS Example</title>
|
<title>FrontendJS Example</title>
|
||||||
</head>
|
</head>
|
||||||
<body>
|
|
||||||
<script src="frontend.js"></script>
|
<script src="frontend.js"></script>
|
||||||
<script>
|
<script>
|
||||||
|
initBody()
|
||||||
clearPage()
|
clearPage()
|
||||||
let firstH1 = createElement("h1", "h1-1")
|
writeHTML("body", markdownToHTML(`# Hello world!
|
||||||
writeText("h1-1", "Hello, world")
|
|
||||||
createParagraph("paragraph1", `This is an example of how to properly use Frontend JS.
|
This is an example of how to properly use Frontend JS.
|
||||||
Also it's a test if things are working.`)
|
Also it's a test if things are working.
|
||||||
|
|
||||||
|
* Air
|
||||||
|
* Water
|
||||||
|
* Fire
|
||||||
|
* Dirt
|
||||||
|
* ####ing magnets, how do they work!?!
|
||||||
|
`))
|
||||||
|
createParagraph("paragraphLorum", `Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed pulvinar nisl eu risus tincidunt, non aliquet metus tempor. Duis ac tortor commodo, venenatis leo at, consectetur nulla.`)
|
||||||
let dino = createButton("dino", "dino sound")
|
let dino = createButton("dino", "dino sound")
|
||||||
changeAttributes(dino, {"onclick": "playAudio(`https://interactive-examples.mdn.mozilla.net/media/cc0-audio/t-rex-roar.mp3`, 0.4)"})
|
changeAttributes(dino, {"onclick": "playAudio(`https://interactive-examples.mdn.mozilla.net/media/cc0-audio/t-rex-roar.mp3`, 0.4)"})
|
||||||
</script>
|
</script>
|
||||||
</body>
|
|
||||||
</html>
|
</html>
|
Loading…
Reference in a new issue