You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We don’t blanketly rewrite a[href] because it’s often used to link to another page, and pages don’t live in _file. But we should be able to tell whether a link is a link to a page or not (because we know how to resolve pages) — and for that matter, we want to normalize and rewrite links to pages anyway (to remove .md and to add .html for non-clean URLs).
The text was updated successfully, but these errors were encountered:
Consider the following HTML:
The
img[src]
attribute is rewritten as expected, but thea[href]
is not, so you get this:We do rewrite
a[href]
attribute when there’s alsoa[download]
:https://github.com/observablehq/cli/blob/205d09b88907899a63fe9f4931715456d4055b6d/src/markdown.ts#L326
We don’t blanketly rewrite
a[href]
because it’s often used to link to another page, and pages don’t live in_file
. But we should be able to tell whether a link is a link to a page or not (because we know how to resolve pages) — and for that matter, we want to normalize and rewrite links to pages anyway (to remove.md
and to add.html
for non-clean URLs).The text was updated successfully, but these errors were encountered: