« get me outta code hell

social embeds (discord, maybe twitter) - hsmusic-wiki - HSMusic - static wiki software cataloguing collaborative creation
about summary refs log tree commit diff
path: root/src/util/html.js
diff options
context:
space:
mode:
author(quasar) nebula <qznebula@protonmail.com>2022-05-15 23:50:42 -0300
committer(quasar) nebula <qznebula@protonmail.com>2022-05-15 23:50:42 -0300
commitebded2fc40c3ff2faead343b9f68d768e6db2c32 (patch)
tree73aee0ff6437053f11fd63691945b6b0e62d6557 /src/util/html.js
parent44104a8970a10dff2894745f0c904644ca3234e0 (diff)
social embeds (discord, maybe twitter)
Tracks only for now, but more will come Soon(TM)!
Diffstat (limited to 'src/util/html.js')
-rw-r--r--src/util/html.js19
1 files changed, 17 insertions, 2 deletions
diff --git a/src/util/html.js b/src/util/html.js
index 94756984..a9b4bb9b 100644
--- a/src/util/html.js
+++ b/src/util/html.js
@@ -1,7 +1,22 @@
 // Some really simple functions for formatting HTML content.
 
-// Non-comprehensive. ::::P
-export const selfClosingTags = ['br', 'img'];
+// COMPREHENSIVE!
+// https://html.spec.whatwg.org/multipage/syntax.html#void-elements
+export const selfClosingTags = [
+    'area',
+    'base',
+    'br',
+    'col',
+    'embed',
+    'hr',
+    'img',
+    'input',
+    'link',
+    'meta',
+    'source',
+    'track',
+    'wbr',
+];
 
 // Pass to tag() as an attri8utes key to make tag() return a 8lank string
 // if the provided content is empty. Useful for when you'll only 8e showing