Fix relative links in markdown preview

This commit is contained in:
Matt Bierner
2017-01-24 11:41:18 -08:00
parent 2854996ca5
commit 4e7666da14

View File

@@ -113,7 +113,7 @@ export class MarkdownEngine {
md.normalizeLink = (link: string) => {
try {
let uri = vscode.Uri.parse(link);
if (!uri.scheme) {
if (!uri.scheme && !uri.fragment) {
// Assume it must be a file
if (uri.path[0] === '/') {
uri = vscode.Uri.file(path.join(vscode.workspace.rootPath, uri.path));