Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/viko16/vuepress-plugin-permalink-pinyin
A VuePress plugin which convert Chinese title to transliterate permalink.
https://github.com/viko16/vuepress-plugin-permalink-pinyin
vuepress-plugin
Last synced: 7 days ago
JSON representation
A VuePress plugin which convert Chinese title to transliterate permalink.
- Host: GitHub
- URL: https://github.com/viko16/vuepress-plugin-permalink-pinyin
- Owner: viko16
- License: mit
- Created: 2019-02-03T03:46:29.000Z (almost 6 years ago)
- Default Branch: master
- Last Pushed: 2022-05-03T07:03:27.000Z (over 2 years ago)
- Last Synced: 2024-09-21T08:13:54.286Z (about 2 months ago)
- Topics: vuepress-plugin
- Language: JavaScript
- Size: 8.79 KB
- Stars: 10
- Watchers: 2
- Forks: 1
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# vuepress-plugin-permalink-pinyin
[![npm](https://img.shields.io/npm/v/vuepress-plugin-permalink-pinyin.svg)](https://www.npmjs.com/package/vuepress-plugin-permalink-pinyin)
[![LICENSE](https://img.shields.io/npm/l/vuepress-plugin-permalink-pinyin.svg)](https://github.com/viko16/vuepress-plugin-permalink-pinyin/blob/master/LICENSE)
[![Dependency Status](https://david-dm.org/viko16/vuepress-plugin-permalink-pinyin.svg?theme=shields.io)](https://david-dm.org/viko16/vuepress-plugin-permalink-pinyin)A VuePress plugin which convert Chinese title to transliterate permalink.
> `/你今日饮咗未.md` => `/ni-jin-ri-yin-zuo-wei.html`
## Installation
> Note: Work For VuePress 1.x.x
```bash
npm i vuepress-plugin-permalink-pinyin --save-dev
# or
yarn add vuepress-plugin-permalink-pinyin --dev
```## Usage
Modify your `.vuepress/config.js` and add into the `plugins` option.
```js
plugins: ['permalink-pinyin']
```## Options
Pass any options of [transliteration#slugify](https://github.com/dzcpy/transliteration#slugifystr-options)
```js
plugins: {
'permalink-pinyin': {
lowercase: true, // Converted into lowercase, default: true
separator: '-' // Separator of the slug, default: '-'
}
}
```## Test
```bash
npm test
```## Related Projects
- Hexo version: https://github.com/viko16/hexo-permalink-pinyin
## License
[MIT License](https://opensource.org/licenses/MIT) © [viko16](https://github.com/viko16)