Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/imyelo/docsify-pagination
↔️ Pagination for docsify
https://github.com/imyelo/docsify-pagination
docsify navigation pagination plugin
Last synced: 7 days ago
JSON representation
↔️ Pagination for docsify
- Host: GitHub
- URL: https://github.com/imyelo/docsify-pagination
- Owner: imyelo
- License: mit
- Created: 2017-12-11T14:10:00.000Z (almost 7 years ago)
- Default Branch: master
- Last Pushed: 2024-11-10T01:39:51.000Z (11 days ago)
- Last Synced: 2024-11-10T02:25:37.953Z (11 days ago)
- Topics: docsify, navigation, pagination, plugin
- Language: JavaScript
- Homepage:
- Size: 447 KB
- Stars: 108
- Watchers: 5
- Forks: 34
- Open Issues: 3
-
Metadata Files:
- Readme: readme.md
- License: license
Awesome Lists containing this project
README
# docsify-pagination
> Pagination for docsify[![npm](https://img.shields.io/npm/v/docsify-pagination.svg?style=flat-square)](https://www.npmjs.com/package/docsify-pagination)
[![license](https://img.shields.io/github/license/imyelo/docsify-pagination.svg?style=flat-square)](./LICENSE)
[![PRs Welcome](https://img.shields.io/badge/PRs-welcome-brightgreen.svg?style=flat-square)](http://makeapullrequest.com)## How does it look like?
![screenshot](./_medias/screenshot.png)## Install
1. insert script into document```html
```2. specify the label text (optional)
```javascript
window.$docsify = {
// ...
pagination: {
previousText: '上一章节',
// or
nextText: {
'/en/': 'NEXT',
'/': '下一章节'
},
crossChapter: true,
crossChapterText: true,
},
}
```## Options
### pagination.previousText
* **Default:** ``'PREVIOUS'``
* **Type:** ``String | Object``
* **Description:** The text of previous label.### pagination.nextText
* **Default:** ``'NEXT'``
* **Type:** ``String | Object``
* **Description:** The text of next label.### pagination.crossChapter
* **Default:** `false`
* **Type:** ``Boolean``
* **Description:** Allow navigation to previous/next chapter.### pagination.crossChapterText
* **Default:** `false`
* **Type:** ``Boolean``
* **Description:** Display chapter name.### ~~pagination.routerMode~~
* **Deprecated**
* **Default:** [`window.$docsify.routerMode`](https://docsify.js.org/#/configuration?id=routermode)
* **Type:** ``String``
* **Description:** Router mode. In most cases, you don't need to modify it. Docsify-Pagination will take care of it for you.## Example
### Run example on local- [Example](example/default/index.html)
- [Example with Docsify's History Route-Mode](example/router-mode-history/index.html)
- [Example with Localization](example/router-mode-history/index.html)#### How to open these?
```bash
$ git clone https://github.com/imyelo/docsify-pagination.git && cd docsify-pagination && yarn
$ yarn example
```### Online Showcase
- [Tina.js](https://tina.js.org/)
- [😘 Tell us yours ...](https://github.com/imyelo/docsify-pagination/edit/master/readme.md)## Related
- [docsify](https://github.com/QingWei-Li/docsify/)## License
MIT © [yelo](https://github.com/imyelo)