Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix: When relativePath: false, use root absolute paths are for images… #1792

Closed
wants to merge 4 commits into from

Conversation

ikfly
Copy link

@ikfly ikfly commented Apr 22, 2022

…ve method as use same router with markdown file then remove beginning # (#877#850)

Summary

When relativePath: false, use root absolute paths for images,a small change as use same router with .md file ,fix #877#850

What kind of change does this PR introduce?

Bugfix

For any code change,

  • Related documentation has been updated if needed
  • Related tests have been updated or tests have been added

Does this PR introduce a breaking change? (check one)

  • Yes
  • No

If yes, please describe the impact and migration path for existing applications:

Related issue, if any:

#877 #850

Tested in the following browsers:

  • Chrome
  • Firefox
  • Safari
  • Edge
  • IE

my tests

  • relativePath: false
currentPath: /doc/home
href: images/myImage.png
url: /images/myImage.png
currentPath: /doc/home
href: https://github.com/docsifyjs/docsify/blob/develop/docs/_images/zh-cn/nested-navbar.png
url: https://github.com/docsifyjs/docsify/blob/develop/docs/_images/zh-cn/nested-navbar.png
  • relativePath: true
currentPath: /doc/home
href: images/myImage.png
url: /doc/images/myImage.png
currentPath: /doc/home
href: https://github.com/docsifyjs/docsify/blob/develop/docs/_images/zh-cn/nested-navbar.png
url: https://github.com/docsifyjs/docsify/blob/develop/docs/_images/zh-cn/nested-navbar.png

…, solve method as use same router with markdown file then remove beginning "#" (docsifyjs#877docsifyjs#850)
@vercel
Copy link

vercel bot commented Apr 22, 2022

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated
docsify-preview ✅ Ready (Inspect) Visit Preview Jul 8, 2022 at 10:48AM (UTC)

@codesandbox-ci
Copy link

codesandbox-ci bot commented Apr 22, 2022

This pull request is automatically built and testable in CodeSandbox.

To see build info of the built libraries, click here or the icon next to each commit SHA.

Latest deployment of this branch, based on commit 1c8c59d:

Sandbox Source
docsify-template Configuration

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.

When relativePath: true, even absolute paths are for icons in sidebar are resolved as relative.
1 participant