Skip to content

Commit 652d048

Browse files
committed
use jsdelivr instead of unpkg, try catch just to be sure
1 parent 0efcdd7 commit 652d048

File tree

4 files changed

+9
-5
lines changed

4 files changed

+9
-5
lines changed

Cargo.lock

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "flash"
3-
version = "0.3.0"
3+
version = "0.3.1"
44
edition = "2021"
55
authors = ["HJfod", "matcool"]
66
description = "Documentation generator for C++"
@@ -34,7 +34,6 @@ anyhow = "1.0.68"
3434
minify-html = "0.15.0"
3535
lightningcss = "1.0.0-alpha.57"
3636
ico = "0.3.0"
37-
3837
# avoid ahash 0.7.x since its broken on newer rust
3938
ahash = "0.8.11"
4039
log = "0.4.26"

templates/head.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
<script src="https://cdn.jsdelivr.net/npm/[email protected]/plugins/autoloader/prism-autoloader.min.js"></script>
2121
<script src="https://cdn.jsdelivr.net/npm/[email protected]/plugins/line-numbers/prism-line-numbers.min.js"></script>
2222
<script src="https://cdn.jsdelivr.net/npm/[email protected]/plugins/autolinker/prism-autolinker.min.js"></script>
23-
<script src="https://unpkg.com/twemoji@latest/dist/twemoji.min.js" crossorigin="anonymous"></script>
23+
<script src="https://cdn.jsdelivr.net/npm/twemoji/dist/twemoji.min.js"></script>
2424
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/[email protected]/plugins/line-numbers/prism-line-numbers.css" data-noprefix />
2525
<link rel="stylesheet" href="{output_url}/themes.css">
2626
<link rel="stylesheet" href="{output_url}/default.css">

templates/script.js

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -549,7 +549,12 @@ function toggleMenu() {
549549
await buildNav();
550550

551551
// Highlight everything
552-
highlight();
552+
try {
553+
highlight();
554+
} catch (e) {
555+
console.error("Highlighting failed.. oops");
556+
console.error(e);
557+
}
553558

554559
// Mark the current page in nav as seleted
555560
{

0 commit comments

Comments
 (0)