diff options
-rw-r--r-- | src/mixins/head.pug | 10 | ||||
-rw-r--r-- | src/views/comments.pug | 8 | ||||
-rw-r--r-- | src/views/index.pug | 11 | ||||
-rw-r--r-- | src/views/subs.pug | 8 |
4 files changed, 16 insertions, 21 deletions
diff --git a/src/mixins/head.pug b/src/mixins/head.pug new file mode 100644 index 0000000..f7c1baf --- /dev/null +++ b/src/mixins/head.pug | |||
@@ -0,0 +1,10 @@ | |||
1 | mixin head() | ||
2 | head | ||
3 | meta(name="viewport" content="width=device-width, initial-scale=1.0") | ||
4 | meta(charset='UTF-8') | ||
5 | title reddit | ||
6 | link(rel="stylesheet", href="/styles.css") | ||
7 | link(rel="preconnect" href="https://rsms.me/") | ||
8 | link(rel="stylesheet" href="https://rsms.me/inter/inter.css") | ||
9 | script(src="https://cdn.dashjs.org/latest/dash.all.min.js") | ||
10 | |||
diff --git a/src/views/comments.pug b/src/views/comments.pug index 9210d96..50c54ec 100644 --- a/src/views/comments.pug +++ b/src/views/comments.pug | |||
@@ -1,15 +1,11 @@ | |||
1 | include ../mixins/comment | 1 | include ../mixins/comment |
2 | include ../mixins/header | 2 | include ../mixins/header |
3 | include ../mixins/head | ||
3 | include ../utils | 4 | include ../utils |
4 | 5 | ||
5 | doctype html | 6 | doctype html |
6 | html | 7 | html |
7 | head | 8 | +head() |
8 | meta(charset='UTF-8') | ||
9 | meta(name="viewport" content="width=device-width, initial-scale=1.0") | ||
10 | title reddit | ||
11 | link(rel='stylesheet', href='/styles.css') | ||
12 | script(src="https://cdn.dashjs.org/latest/dash.all.min.js") | ||
13 | script. | 9 | script. |
14 | function toggleDetails(details_id) { | 10 | function toggleDetails(details_id) { |
15 | var detailsElement = document.getElementById(details_id); | 11 | var detailsElement = document.getElementById(details_id); |
diff --git a/src/views/index.pug b/src/views/index.pug index 5367b41..0988b08 100644 --- a/src/views/index.pug +++ b/src/views/index.pug | |||
@@ -1,19 +1,12 @@ | |||
1 | include ../mixins/post | 1 | include ../mixins/post |
2 | include ../mixins/sub | 2 | include ../mixins/sub |
3 | include ../mixins/header | 3 | include ../mixins/header |
4 | include ../mixins/head | ||
4 | include ../utils | 5 | include ../utils |
5 | - var subs = [] | 6 | - var subs = [] |
6 | doctype html | 7 | doctype html |
7 | html | 8 | html |
8 | head | 9 | +head() |
9 | meta(name="viewport" content="width=device-width, initial-scale=1.0") | ||
10 | meta(charset='UTF-8') | ||
11 | title reddit | ||
12 | link(rel="stylesheet", href="/styles.css") | ||
13 | link(rel="preconnect" href="https://rsms.me/") | ||
14 | link(rel="stylesheet" href="https://rsms.me/inter/inter.css") | ||
15 | script(src="https://cdn.dashjs.org/latest/dash.all.min.js") | ||
16 | |||
17 | +subMgmt() | 10 | +subMgmt() |
18 | script. | 11 | script. |
19 | function updateButton(sub) { | 12 | function updateButton(sub) { |
diff --git a/src/views/subs.pug b/src/views/subs.pug index 2d2ee4f..f7e2b81 100644 --- a/src/views/subs.pug +++ b/src/views/subs.pug | |||
@@ -1,14 +1,10 @@ | |||
1 | include ../mixins/sub | 1 | include ../mixins/sub |
2 | include ../mixins/header | 2 | include ../mixins/header |
3 | include ../mixins/head | ||
3 | 4 | ||
4 | doctype html | 5 | doctype html |
5 | html | 6 | html |
6 | head | 7 | +head() |
7 | meta(charset='UTF-8') | ||
8 | meta(name="viewport" content="width=device-width, initial-scale=1.0") | ||
9 | title reddit | ||
10 | link(rel='stylesheet', href='/styles.css') | ||
11 | |||
12 | +subMgmt() | 8 | +subMgmt() |
13 | script. | 9 | script. |
14 | function newSubItem(sub) { | 10 | function newSubItem(sub) { |