We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 934c57d commit 1e6852cCopy full SHA for 1e6852c
src/Mdx.res
@@ -129,10 +129,13 @@ let remarkReScriptPrelude = tree => {
129
let remarkLinkPlugin = (tree, vfile) => {
130
visit(tree, "link", node => {
131
let url = node["url"]
132
- let filePath =
133
- vfile["history"][0]->Option.getOrThrow(
134
- ~message=`File path not found for vfile: ${node["url"]}`,
135
- )
+ let filePath = switch vfile["history"][0] {
+ | Some(path) => path
+ | None => {
+ Console.error2("File path not found for vfile:", JSON.stringifyAny(node["url"]))
136
+ ""
137
+ }
138
139
140
// Direct links to the homepage are OK
141
if url == "https://rescript-lang.org" {
0 commit comments