Support relative markdown link navigation #3
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Type
Feature
Lineage
Repo
ldraney/mdview
User Story
As a user, I want to click relative links to other
.mdfiles (e.g.docs/user-stories.md) in the rendered view and have them render through mdview, so I can navigate a doc tree in the browser.Context
Currently mdview only renders the single file passed via CLI. Markdown docs commonly link to each other with relative paths. These links should resolve to the mdview renderer, not 404.
Description
MDVIEW_FILE.mdfile relative to that base dir.mdhrefs to mdview routes/rendering the original entry fileFile Targets
config/routes.rb-- add catch-all routeapp/controllers/markdown_controller.rb-- path resolution, link rewritingAcceptance Criteria
.mdlink navigates to the rendered file.mdfiles are left untouched../../../etc/passwd) is blocked/still renders the entry fileTest Expectations
[link](docs/foo.md)renders, click navigates to foo.mdConstraints
Checklist
Related
Follows from initial scaffold and #1.