You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/README.md
+8-2Lines changed: 8 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -98,6 +98,8 @@ As usual external resource can be linked e.g. `https://example.com`.
98
98
99
99
**Rules for internal links**
100
100
101
+
DocsifJS will render markdown links in your docs as appropriate paths in the DocsifyJS structure.
102
+
101
103
Apply these rules to the latter part of markdown URLs such as `[Text](page.md)`.
102
104
103
105
- Links must always be relative to the `docs` directory and **not** to the file containing the link.
@@ -107,9 +109,13 @@ Apply these rules to the latter part of markdown URLs such as `[Text](page.md)`.
107
109
- e.g. `/foo.md`, which becomes `/#/foo`.
108
110
- Links may use an ID.
109
111
- e.g. To link to heading on the homepage, use `#my-project`, which gets converted to `/#/?id=my-project`.
110
-
- e.g. To link to another page, use `foo.md#my-project`.
112
+
- e.g. To link to another page, use `foo.md#my-project`, which becomes `/#/foo.md?idmy-project`.
111
113
- Do not reference the `docs` directory in the path. e.g. `/docs/foo.md`
112
-
- Do not refer to content outside of the `docs` directory. e.g. `../README.md`
114
+
- Do not refer to content outside of the `docs` directory. e.g. `../README.md`.
115
+
- If you use relative links between files in the `docs` directory - make sure to enable this in the app config.
116
+
117
+
118
+
!> Be careful when using HTML tags that have links or avoid them. <br>HTML tag hyperlinks will be rendered literally and so will break in the Docsify path structure e.g. `foo.md` or `foo.md#my-project`. <br> You can set them up manually, which makes them harder to maintain if your site structure changes. e.g. `href="/#/id=my-project"` or `href="/#/foo.md?id=my-project"`
0 commit comments