Add docs
diff --git a/colors.webm b/colors.webm
deleted file mode 100644
index e32b42f..0000000
--- a/colors.webm
+++ /dev/null
Binary files differ
diff --git a/docs/build.lua b/docs/build.lua
new file mode 100644
index 0000000..c7a50e1
--- /dev/null
+++ b/docs/build.lua
@@ -0,0 +1,15 @@
+require "blackjack"
+
+site = Site
+
+-- site.processors.md = markdownProcessor
+site.processors.scss = {
+ process = cmdProcessor("sass -"),
+ extension = "css"
+}
+site.processors.webm = {
+ process = cmdProcessor("cat"),
+ extension = "webm"
+}
+
+site:build()
diff --git a/docs/build.sh b/docs/build.sh
new file mode 100644
index 0000000..1046c73
--- /dev/null
+++ b/docs/build.sh
@@ -0,0 +1,9 @@
+luajit build.lua
+
+CURRENT_WID=$(xdotool getwindowfocus)
+
+WID=$(xdotool search --name "Mozilla Firefox")
+xdotool windowactivate $WID
+xdotool key F5
+
+xdotool windowactivate $CURRENT_WID
diff --git a/docs/content/CNAME b/docs/content/CNAME
new file mode 100644
index 0000000..14ec71f
--- /dev/null
+++ b/docs/content/CNAME
@@ -0,0 +1 @@
+6502.swisschili.sh
\ No newline at end of file
diff --git a/docs/content/building.md b/docs/content/building.md
new file mode 100644
index 0000000..fea14ff
--- /dev/null
+++ b/docs/content/building.md
@@ -0,0 +1,29 @@
+@parent = page.html
+@title = Building
+
+# Building from source
+
+You need the following libraries installed to build the emulator:
+
+`pthread` `rt` `m` `SDL2` `GL` `GLEW` `GLU` `readline`
+
+The first three will be included on any POSIX compliant operating system (OS X, Linux, BSD, etc).
+To install SDL2, visit its <a href="https://www.libsdl.org/">website</a> or use your distributions
+package manager.
+
+<br>
+You also need `awk` installed if you want to modify the `6502.csv` file from which parts of the
+emulator are generated. If you don't want to do this, run cmake with `-DGEN_INSTRUCTIONS_HEADER=OFF`
+
+<br>
+You may be able to build this on Windows using Cygwin or MinGW, but I haven't tested that.
+
+<br>
+Run the usual commands to build with cmake:
+```
+$ mkdir build
+$ cd build
+$ cmake ..
+$ make -j
+$ ./6502 # you built it, nice
+```
diff --git a/docs/content/colors.dat b/docs/content/colors.dat
new file mode 100644
index 0000000..aea5970
--- /dev/null
+++ b/docs/content/colors.dat
Binary files differ
diff --git a/docs/content/demo.webm b/docs/content/demo.webm
new file mode 100644
index 0000000..fba477a
--- /dev/null
+++ b/docs/content/demo.webm
Binary files differ
diff --git a/docs/content/disco.dat b/docs/content/disco.dat
new file mode 100644
index 0000000..b004f7a
--- /dev/null
+++ b/docs/content/disco.dat
Binary files differ
diff --git a/docs/content/examples.md b/docs/content/examples.md
new file mode 100644
index 0000000..9b8e1c2
--- /dev/null
+++ b/docs/content/examples.md
@@ -0,0 +1,56 @@
+@parent = page.html
+@title = Examples
+
+# Example Programs
+
+Download the compiled programs and try them out in the emulator!
+
+### Colors
+
+Draws every supported color on the screen.
+<a href="colors.dat" download>Download</a>
+
+```
+ LDY #$0
+loop:
+ TYA
+ STA $200, Y
+ STA $300, Y
+ STA $400, Y
+ STA $500, Y
+ INY
+ CMP #$ff
+ BCC loop
+ BRK
+```
+
+### Disco
+
+Epilepsy warning: lots of flashing colors. Due to how much faster this emulator is
+than the one this program was written for, it's more of just flashing colors than
+what it originally looked like.
+<a href="disco.dat" download>Download</a>
+
+```
+; Taken from 6502asm.com
+
+start:
+ inx
+ txa
+ sta $200, y
+ sta $300, y
+ sta $400, y
+ sta $500, y
+ iny
+ tya
+ cmp 16
+ bne do
+ iny
+ jmp start
+do:
+ iny
+ iny
+ iny
+ iny
+ jmp start
+```
diff --git a/docs/content/index.md b/docs/content/index.md
new file mode 100644
index 0000000..48d4508
--- /dev/null
+++ b/docs/content/index.md
@@ -0,0 +1,42 @@
+@parent = page.html
+@title = Home
+
+# 6502 Toolchain
+
+<center>
+ <video controls="true">
+ <source src="demo.webm" type="video/webm">
+ </video>
+</center>
+
+This project aims to create a fast, powerful, and easy to use toolchain for writing, debugging,
+and running programs for the 6502 processor. It features a graphical and CLI debugger, disassembler,
+and emulator.
+
+
+## Features
+
+### 8 bit color
+
+That's 16 times more colors than <a href="http://6502asm.com/" target="_blank">the competition</a>!
+
+### Graphical debugger
+
+Easily step through, run, and debug your programs using a fast graphical debugger. A traditional
+CLI debugger is also available.
+
+### Fully multithreaded
+
+The graphical debugger, cli debugger, and screen are all fully asynchronous. That means your
+debugger stays fast, even when the emulator is running at full capacity.
+It will soon be possible to even debug an already running instance of the emulator!
+
+### *Fast*
+
+This emulator is incredibly fast. So fast that programs written for other emulators don't work
+properly half the time because of how fast it is! At some point I will add an option to slow
+the emulator down so it is comparable to other emulators.
+
+<br>
+
+So what are you waiting for? Download the emulator now, or build it from source.
\ No newline at end of file
diff --git a/docs/content/styles.scss b/docs/content/styles.scss
new file mode 100644
index 0000000..dfd1940
--- /dev/null
+++ b/docs/content/styles.scss
@@ -0,0 +1,68 @@
+html,
+body
+{
+ font-family: /*'Segoe UI', 'Roboto', 'San Francisco', 'IBM Plex Sans',*/ sans-serif;
+}
+
+body
+{
+ display: grid;
+ place-items: center center
+}
+
+
+h4 code
+{
+ font-size: 1.5em;
+}
+
+code
+{
+ background: #f2f4f4;
+ border-radius: 5px;
+ padding: 3px 5px 3px 5px;
+}
+
+.container
+{
+ width: 60em;
+}
+
+.nav
+{
+ font-size: 1.5rem;
+ display: flex;
+ flex-direction: row;
+
+ .wide
+ {
+ flex: 1;
+ font-weight: bold;
+ }
+}
+
+.split
+{
+ display: grid;
+ grid-template-columns: 16em auto;
+}
+
+video
+{
+ width: 100%;
+}
+
+@media screen and (max-width: 58em)
+{
+ .split
+ {
+ display: flex;
+ flex-direction: column;
+ }
+
+ .container
+ {
+ width: calc(100% - 2em);
+ margin: 1em;
+ }
+}
diff --git a/docs/content/usage.md b/docs/content/usage.md
new file mode 100644
index 0000000..fb18254
--- /dev/null
+++ b/docs/content/usage.md
@@ -0,0 +1,46 @@
+@parent = page.html
+@title = Usage
+
+# Basic Usage
+
+The `6502` command takes some arguments that control how it functions. Each flag is documented
+here. Note that only UNIX style flags are supported, not GNU style. This uses the standard
+`getopt()` function, so flags work the same as any UNIX command.
+
+#### `-g`
+
+Opens a GUI debugger window.
+
+#### `-s`
+
+Opens a window that shows the emulators screen. Cannot be used in conjunction with `-g`.
+
+#### `-H`
+
+Keep the emulator running after the CPU halts (after an interrupt is triggered). Useful
+for debugging short programs. Does nothing when used with `-D`.
+
+#### `-d`
+
+Disassemble the input file, printing the whole disassembly to `stdout`. You probably want
+to use this with `-n`
+
+#### `-r`
+
+Run the input file. Can be used in conjunction with `-s` to run and display the output.
+
+#### `-D`
+
+Open CLI debugger. Can be used with `-s` to view screen while debugging.
+
+#### `-i input`
+
+Read `input` into the CPUs memory.
+
+#### `-n number_of_instructions`
+
+Disassemble only `number_of_instructions` instructions.
+
+#### `-h, -?`
+
+Print a help message.
diff --git a/docs/site/CNAME b/docs/site/CNAME
new file mode 100644
index 0000000..14ec71f
--- /dev/null
+++ b/docs/site/CNAME
@@ -0,0 +1 @@
+6502.swisschili.sh
\ No newline at end of file
diff --git a/docs/site/building.html b/docs/site/building.html
new file mode 100644
index 0000000..e48114b
--- /dev/null
+++ b/docs/site/building.html
@@ -0,0 +1,61 @@
+<html>
+ <head>
+ <meta name="viewport" content="width=device-width">
+ <link rel="stylesheet"
+ href="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.18.1/styles/default.min.css">
+ <link rel="stylesheet" href="styles.css">
+ <title>Building</title>
+ </head>
+ <body>
+ <main class="split container">
+ <div class="sidebar">
+ <h2><a href="/">6502</a></h2>
+
+ <p>
+ 6502 Toolchain written by <a href="https://github.com/swissChili">swissChili</a>
+ </p>
+
+ <ul>
+ <li><a href="https://github.com/swissChili/6502">Git</a></li>
+ <li><a href="/usage.html">Basic usage</a></li>
+ <li><a href="/examples.html">Example programs</a></li>
+ <li><a href="/building.html">Building from source</a></li>
+ </ul>
+ </div>
+ <div class="body">
+ <h1> Building from source</h1>
+You need the following libraries installed to build the emulator:
+<br>
+<code>pthread</code> <code>rt</code> <code>m</code> <code>SDL2</code> <code>GL</code> <code>GLEW</code> <code>GLU</code> <code>readline</code>
+<br>
+The first three will be included on any POSIX compliant operating system (OS X, Linux, BSD, etc).
+To install SDL2, visit its <a href="https://www.libsdl.org/">website</a> or use your distributions
+package manager.
+<br>
+<br>
+You also need <code>awk</code> installed if you want to modify the <code>6502.csv</code> file from which parts of the
+emulator are generated. If you don't want to do this, run cmake with <code>-DGEN_INSTRUCTIONS_HEADER=OFF</code>
+<br>
+<br>
+You may be able to build this on Windows using Cygwin or MinGW, but I haven't tested that.
+<br>
+<br>
+Run the usual commands to build with cmake:
+<pre><code class>$ mkdir build
+$ cd build
+$ cmake ..
+$ make -j
+$ ./6502 # you built it, nice</code></pre>
+ </div>
+ </main>
+
+ <script src="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.18.1/highlight.min.js"></script>
+ <script>
+ document.addEventListener('DOMContentLoaded', (event) => {
+ document.querySelectorAll('pre code').forEach((block) => {
+ hljs.highlightBlock(block);
+ });
+ });
+ </script>
+ </body>
+</html>
diff --git a/docs/site/colors.dat b/docs/site/colors.dat
new file mode 100644
index 0000000..aea5970
--- /dev/null
+++ b/docs/site/colors.dat
Binary files differ
diff --git a/docs/site/demo.webm b/docs/site/demo.webm
new file mode 100644
index 0000000..fba477a
--- /dev/null
+++ b/docs/site/demo.webm
Binary files differ
diff --git a/docs/site/disco.dat b/docs/site/disco.dat
new file mode 100644
index 0000000..b004f7a
--- /dev/null
+++ b/docs/site/disco.dat
Binary files differ
diff --git a/docs/site/examples.html b/docs/site/examples.html
new file mode 100644
index 0000000..b5bc79c
--- /dev/null
+++ b/docs/site/examples.html
@@ -0,0 +1,82 @@
+<html>
+ <head>
+ <meta name="viewport" content="width=device-width">
+ <link rel="stylesheet"
+ href="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.18.1/styles/default.min.css">
+ <link rel="stylesheet" href="styles.css">
+ <title>Examples</title>
+ </head>
+ <body>
+ <main class="split container">
+ <div class="sidebar">
+ <h2><a href="/">6502</a></h2>
+
+ <p>
+ 6502 Toolchain written by <a href="https://github.com/swissChili">swissChili</a>
+ </p>
+
+ <ul>
+ <li><a href="https://github.com/swissChili/6502">Git</a></li>
+ <li><a href="/usage.html">Basic usage</a></li>
+ <li><a href="/examples.html">Example programs</a></li>
+ <li><a href="/building.html">Building from source</a></li>
+ </ul>
+ </div>
+ <div class="body">
+ <h1> Example Programs</h1>
+Download the compiled programs and try them out in the emulator!
+<h3> Colors</h3>
+Draws every supported color on the screen.
+<a href="colors.dat" download>Download</a>
+<br>
+<pre><code class> LDY #$0
+loop:
+ TYA
+ STA $200, Y
+ STA $300, Y
+ STA $400, Y
+ STA $500, Y
+ INY
+ CMP #$ff
+ BCC loop
+ BRK</code></pre>
+<h3> Disco</h3>
+Epilepsy warning: lots of flashing colors. Due to how much faster this emulator is
+than the one this program was written for, it's more of just flashing colors than
+what it originally looked like.
+<a href="disco.dat" download>Download</a>
+<br>
+<pre><code class>; Taken from 6502asm.com
+<br>
+start:
+ inx
+ txa
+ sta $200, y
+ sta $300, y
+ sta $400, y
+ sta $500, y
+ iny
+ tya
+ cmp 16
+ bne do
+ iny
+ jmp start
+do:
+ iny
+ iny
+ iny
+ iny
+ jmp start</code></pre>
+ </div>
+ </main>
+
+ <script src="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.18.1/highlight.min.js"></script>
+ <script>
+ document.addEventListener('DOMContentLoaded', (event) => {
+ document.querySelectorAll('pre code').forEach((block) => {
+ hljs.highlightBlock(block);
+ });
+ });
+ </script>
+ </body>
+</html>
diff --git a/docs/site/index.html b/docs/site/index.html
new file mode 100644
index 0000000..a26b13e
--- /dev/null
+++ b/docs/site/index.html
@@ -0,0 +1,66 @@
+<html>
+ <head>
+ <meta name="viewport" content="width=device-width">
+ <link rel="stylesheet"
+ href="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.18.1/styles/default.min.css">
+ <link rel="stylesheet" href="styles.css">
+ <title>Home</title>
+ </head>
+ <body>
+ <main class="split container">
+ <div class="sidebar">
+ <h2><a href="/">6502</a></h2>
+
+ <p>
+ 6502 Toolchain written by <a href="https://github.com/swissChili">swissChili</a>
+ </p>
+
+ <ul>
+ <li><a href="https://github.com/swissChili/6502">Git</a></li>
+ <li><a href="/usage.html">Basic usage</a></li>
+ <li><a href="/examples.html">Example programs</a></li>
+ <li><a href="/building.html">Building from source</a></li>
+ </ul>
+ </div>
+ <div class="body">
+ <h1> 6502 Toolchain</h1>
+<center>
+ <video controls="true">
+ <source src="demo.webm" type="video/webm">
+ </video>
+</center>
+<br>
+This project aims to create a fast, powerful, and easy to use toolchain for writing, debugging,
+and running programs for the 6502 processor. It features a graphical and CLI debugger, disassembler,
+and emulator.
+<br>
+<h2> Features</h2><h3> 8 bit color</h3>
+That's 16 times more colors than <a href="http://6502asm.com/" target="_blank">the competition</a>!
+<h3> Graphical debugger</h3>
+Easily step through, run, and debug your programs using a fast graphical debugger. A traditional
+CLI debugger is also available.
+<h3> Fully multithreaded</h3>
+The graphical debugger, cli debugger, and screen are all fully asynchronous. That means your
+debugger stays fast, even when the emulator is running at full capacity.
+It will soon be possible to even debug an already running instance of the emulator!
+<h3> <i>Fast</i></h3>
+This emulator is incredibly fast. So fast that programs written for other emulators don't work
+properly half the time because of how fast it is! At some point I will add an option to slow
+the emulator down so it is comparable to other emulators.
+<br>
+<br>
+<br>
+So what are you waiting for? Download the emulator now, or build it from source.
+ </div>
+ </main>
+
+ <script src="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.18.1/highlight.min.js"></script>
+ <script>
+ document.addEventListener('DOMContentLoaded', (event) => {
+ document.querySelectorAll('pre code').forEach((block) => {
+ hljs.highlightBlock(block);
+ });
+ });
+ </script>
+ </body>
+</html>
diff --git a/docs/site/index.md b/docs/site/index.md
new file mode 100644
index 0000000..5d5fd9c
--- /dev/null
+++ b/docs/site/index.md
@@ -0,0 +1,9 @@
+@parent = home.html
+@title = Home
+
+<center>
+ <video controls="true">
+ <source src="demo.webm" type="video/webm">
+ </video>
+</center>
+
diff --git a/docs/site/styles.css b/docs/site/styles.css
new file mode 100644
index 0000000..cb6e27f
--- /dev/null
+++ b/docs/site/styles.css
@@ -0,0 +1,54 @@
+html,
+body {
+ font-family: sans-serif;
+}
+
+body {
+ display: grid;
+ place-items: center center;
+}
+
+h4 code {
+ font-size: 1.5em;
+}
+
+code {
+ background: #f2f4f4;
+ border-radius: 5px;
+ padding: 3px 5px 3px 5px;
+}
+
+.container {
+ width: 60em;
+}
+
+.nav {
+ font-size: 1.5rem;
+ display: flex;
+ flex-direction: row;
+}
+.nav .wide {
+ flex: 1;
+ font-weight: bold;
+}
+
+.split {
+ display: grid;
+ grid-template-columns: 16em auto;
+}
+
+video {
+ width: 100%;
+}
+
+@media screen and (max-width: 58em) {
+ .split {
+ display: flex;
+ flex-direction: column;
+ }
+
+ .container {
+ width: calc(100% - 2em);
+ margin: 1em;
+ }
+}
diff --git a/docs/site/styles.scss b/docs/site/styles.scss
new file mode 100644
index 0000000..bee13ef
--- /dev/null
+++ b/docs/site/styles.scss
@@ -0,0 +1,31 @@
+html,
+body {
+ font-family: /*'Segoe UI', 'Roboto', 'San Francisco', 'IBM Plex Sans',*/ sans-serif;
+}
+
+body {
+ display: grid;
+ place-items: center center
+}
+
+.container {
+ width: 50vw;
+}
+
+.nav {
+ font-size: 1.5rem;
+ display: flex;
+ flex-direction: row;
+
+ .wide {
+ flex: 1;
+ font-weight: bold;
+ }
+}
+
+@media screen and (max-width: 960px) {
+ .container {
+ width: calc(100% - 2em);
+ margin: 1em;
+ }
+}
\ No newline at end of file
diff --git a/docs/site/usage.html b/docs/site/usage.html
new file mode 100644
index 0000000..4549b2f
--- /dev/null
+++ b/docs/site/usage.html
@@ -0,0 +1,62 @@
+<html>
+ <head>
+ <meta name="viewport" content="width=device-width">
+ <link rel="stylesheet"
+ href="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.18.1/styles/default.min.css">
+ <link rel="stylesheet" href="styles.css">
+ <title>Usage</title>
+ </head>
+ <body>
+ <main class="split container">
+ <div class="sidebar">
+ <h2><a href="/">6502</a></h2>
+
+ <p>
+ 6502 Toolchain written by <a href="https://github.com/swissChili">swissChili</a>
+ </p>
+
+ <ul>
+ <li><a href="https://github.com/swissChili/6502">Git</a></li>
+ <li><a href="/usage.html">Basic usage</a></li>
+ <li><a href="/examples.html">Example programs</a></li>
+ <li><a href="/building.html">Building from source</a></li>
+ </ul>
+ </div>
+ <div class="body">
+ <h1> Basic Usage</h1>
+The <code>6502</code> command takes some arguments that control how it functions. Each flag is documented
+here. Note that only UNIX style flags are supported, not GNU style. This uses the standard
+<code>getopt()</code> function, so flags work the same as any UNIX command.
+<h4> <code>-g</code></h4>
+Opens a GUI debugger window.
+<h4> <code>-s</code></h4>
+Opens a window that shows the emulators screen. Cannot be used in conjunction with <code>-g</code>.
+<h4> <code>-H</code></h4>
+Keep the emulator running after the CPU halts (after an interrupt is triggered). Useful
+for debugging short programs. Does nothing when used with <code>-D</code>.
+<h4> <code>-d</code></h4>
+Disassemble the input file, printing the whole disassembly to <code>stdout</code>. You probably want
+to use this with <code>-n</code>
+<h4> <code>-r</code></h4>
+Run the input file. Can be used in conjunction with <code>-s</code> to run and display the output.
+<h4> <code>-D</code></h4>
+Open CLI debugger. Can be used with <code>-s</code> to view screen while debugging.
+<h4> <code>-i input</code></h4>
+Read <code>input</code> into the CPUs memory.
+<h4> <code>-n number_of_instructions</code></h4>
+Disassemble only <code>number_of_instructions</code> instructions.
+<h4> <code>-h, -?</code></h4>
+Print a help message.
+ </div>
+ </main>
+
+ <script src="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.18.1/highlight.min.js"></script>
+ <script>
+ document.addEventListener('DOMContentLoaded', (event) => {
+ document.querySelectorAll('pre code').forEach((block) => {
+ hljs.highlightBlock(block);
+ });
+ });
+ </script>
+ </body>
+</html>
diff --git a/docs/site/usage.md b/docs/site/usage.md
new file mode 100644
index 0000000..f3d3272
--- /dev/null
+++ b/docs/site/usage.md
@@ -0,0 +1,4 @@
+@parent = page.html
+@title = Usage
+
+# Basic Usage
\ No newline at end of file
diff --git a/docs/templates/home.html b/docs/templates/home.html
new file mode 100644
index 0000000..bb328e5
--- /dev/null
+++ b/docs/templates/home.html
@@ -0,0 +1,28 @@
+<html>
+ <head>
+ <meta name="viewport" content="width=device-width">
+ <link rel="stylesheet"
+ href="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.18.1/styles/default.min.css">
+ <link rel="stylesheet" href="styles.css">
+ <title>${title}</title>
+ </head>
+ <body>
+ <div class="container">
+ <div class="nav">
+ <a href="/" class="wide">6502</a>
+ <a href="https://github.com/swissChili/6502">Git</a>
+ </div>
+ <hr>
+ ${body}
+ </div>
+
+ <script src="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.18.1/highlight.min.js"></script>
+ <script>
+ document.addEventListener('DOMContentLoaded', (event) => {
+ document.querySelectorAll('pre code').forEach((block) => {
+ hljs.highlightBlock(block);
+ });
+ });
+ </script>
+ </body>
+</html>
diff --git a/docs/templates/page.html b/docs/templates/page.html
new file mode 100644
index 0000000..a9c6219
--- /dev/null
+++ b/docs/templates/page.html
@@ -0,0 +1,39 @@
+<html>
+ <head>
+ <meta name="viewport" content="width=device-width">
+ <link rel="stylesheet"
+ href="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.18.1/styles/default.min.css">
+ <link rel="stylesheet" href="styles.css">
+ <title>${title}</title>
+ </head>
+ <body>
+ <main class="split container">
+ <div class="sidebar">
+ <h2><a href="/">6502</a></h2>
+
+ <p>
+ 6502 Toolchain written by <a href="https://github.com/swissChili">swissChili</a>
+ </p>
+
+ <ul>
+ <li><a href="https://github.com/swissChili/6502">Git</a></li>
+ <li><a href="/usage.html">Basic usage</a></li>
+ <li><a href="/examples.html">Example programs</a></li>
+ <li><a href="/building.html">Building from source</a></li>
+ </ul>
+ </div>
+ <div class="body">
+ ${body}
+ </div>
+ </main>
+
+ <script src="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.18.1/highlight.min.js"></script>
+ <script>
+ document.addEventListener('DOMContentLoaded', (event) => {
+ document.querySelectorAll('pre code').forEach((block) => {
+ hljs.highlightBlock(block);
+ });
+ });
+ </script>
+ </body>
+</html>