https://github.com/buxuku/hexo-generator-latest2json
build a latest post list to a json file
https://github.com/buxuku/hexo-generator-latest2json
Last synced: 8 months ago
JSON representation
build a latest post list to a json file
- Host: GitHub
- URL: https://github.com/buxuku/hexo-generator-latest2json
- Owner: buxuku
- License: mit
- Created: 2021-01-18T08:10:58.000Z (almost 5 years ago)
- Default Branch: main
- Last Pushed: 2021-01-18T15:56:58.000Z (almost 5 years ago)
- Last Synced: 2025-03-13T11:51:15.738Z (9 months ago)
- Language: JavaScript
- Size: 33.2 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# hexo-generator-latest2json
[](https://www.npmjs.com/package/hexo-generator-latest2json)
build a latest post list in a json file. that you can use it for other platforms.
### Installation
```shell
npm i hexo-generator-latest2json -S
```
### Oportions
Add or modify the following sections to you root _config.yml file:
```yaml
latest2json:
number: 10
order_by: '-date'
path: 'latest2json'
fields:
- title
- date
- path
```
* **number**: how many number posts will be generated into the json file
* default: 10
* **order_by** Post order
* default: date descending
* **path** the output path for the json file
* default: 'latest.json'.
* **fields** which fields you want to get from ths post
* default: title, date, path
## License
MIT