Skip to content

Fix wikilinks on folder to markdown link - #1744

Open
Morikko wants to merge 1 commit into
foambubble:mainfrom
Morikko:fix-wikilinks-folder-markdown-link
Open

Morikko wants to merge 1 commit into
foambubble:mainfrom
Morikko:fix-wikilinks-folder-markdown-link

Conversation

@Morikko

@Morikko Morikko commented Oct 16, 2026

Copy link
Copy Markdown

A wikilinks on my-folder/README.md would be [[my-folder]]. But once a conversion is done to generate a normal markdown link [](), it broke as a folder can not be the target:

Failed to convert wikilink to markdown link: Resource "my-folder" not found

The conversion should find a link by considering README.md or index.md.

As I have "foam.completion.linkFormat": "link", I often hit the case if the completion selected is like my-folder/README.md format.

This PR has a fix with a regression test. I also tested a vsix build on my workspace and the issue disappeared.

AI assisted submission with Opus 4.8.

A wikilinks on `my-folder/README.md` would be `[[my-folder]]`. But once a conversion is done to generate a normal markdown link `[]()`, it broke as a folder can not be the target:

```
Failed to convert wikilink to markdown link: Resource "my-folder" not found
```

The conversion should find a link by considering README.md or index.md.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant