Remove 404.html

This commit is contained in:
qingwei.li 2016-12-24 19:50:04 +08:00
commit 67f9083ff7
3 changed files with 16 additions and 39 deletions

View file

@ -8,7 +8,7 @@ mkdir docs && cd docs
```
### Create entry file
Create a `404.html` file
Create a `index.html` file
```html
<!DOCTYPE html>
@ -20,7 +20,7 @@ Create a `404.html` file
<body>
<div id="app"></div>
</body>
<script src="//unpkg.com/docsify"></script>
<script src="//unpkg.com/docsify" data-router></script>
</html>
```
@ -77,27 +77,18 @@ Minified files
## More
### Multiple pages
If you need other pages, directly create the markdown file, such as `guide.md` is `/guide`.
If you need other pages, directly create the markdown file, such as `guide.md` is `/#/guide`.
### Navbar
Code in `404.html`
Code in `index.html`
```html
<nav>
<a href="/docsify/">En</a>
<a href="/docsify/zh-cn">中文</a>
<a href="/#/docsify/">En</a>
<a href="/#/docsify/zh-cn">中文</a>
</nav>
```
### Hash router
`404.html` is not SEO friendly, you can replace it use `index.html` and `data-router` [issue#7](https://github.com/QingWei-Li/docsify/issues/7)
index.html
```html
<script src="//unpkg.com/docsify" data-router></script>
```
### CDN
- UNPKG [https://unpkg.com/docsify/](https://unpkg.com/docsify/)
- jsDelivr [http://www.jsdelivr.com/projects/docsify](http://www.jsdelivr.com/projects/docsify)
@ -242,7 +233,7 @@ If you write a sub level list, it will generate a dropdown list.
#### router
Hash router. You can replace `404.html` with `index.html`.
Hash router.
```html
<script src="/lib/docsify.js" data-router></script>