fix(v2): linking to asset or external html page -> don't use history.push() (#3347)

* Rework markdown links to asset require processing + add test page

* implement pathname:// protocol / escape hatch at the Link level

* linking to assets: fix tests + avoid creating an useless nested paragraph

* fix assets linking doc

* attempt to fix windows e2e test

* try to fix windows errors
This commit is contained in:
Sébastien Lorber 2020-08-28 12:47:03 +02:00 committed by GitHub
parent bd9b6618c1
commit c7fc781ce0
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
21 changed files with 267 additions and 227 deletions

View file

@ -0,0 +1,31 @@
# Markdown tests
This is a test page to see if Docusaurus markdown features are working properly
## Linking to assets
See [#3337](https://github.com/facebook/docusaurus/issues/3337)
- [/dogfooding/someFile.pdf](/dogfooding/someFile.pdf)
- [/dogfooding/someFile.xyz](/dogfooding/someFile.xyz)
- [../../static/dogfooding/someFile.pdf](../../static/dogfooding/someFile.pdf)
- [../../static/dogfooding/someFile.xyz](../../static/dogfooding/someFile.xyz)
- [@site/static/dogfooding/someFile.pdf](@site/static/dogfooding/someFile.pdf)
- [@site/static/dogfooding/someFile.xyz](@site/static/dogfooding/someFile.xyz)
## Linking to non-SPA page hosted within website
See [#3309](https://github.com/facebook/docusaurus/issues/3309)
- [pathname:///dogfooding/javadoc](pathname:///dogfooding/javadoc)
- [pathname:///dogfooding/javadoc/index.html](pathname:///dogfooding/javadoc/index.html)
- [pathname://../dogfooding/javadoc](pathname://../dogfooding/javadoc)
- [pathname://../dogfooding/javadoc/index.html](pathname://../dogfooding/javadoc/index.html)