Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/imabp/blogtraversy
NPM Package that fetches all your blogs from Hashnode and Medium
https://github.com/imabp/blogtraversy
blog hacktoberfest hashnode medium
Last synced: 3 months ago
JSON representation
NPM Package that fetches all your blogs from Hashnode and Medium
- Host: GitHub
- URL: https://github.com/imabp/blogtraversy
- Owner: imabp
- Created: 2021-07-18T11:16:25.000Z (over 3 years ago)
- Default Branch: main
- Last Pushed: 2021-07-31T14:37:42.000Z (over 3 years ago)
- Last Synced: 2024-07-24T16:13:28.664Z (4 months ago)
- Topics: blog, hacktoberfest, hashnode, medium
- Language: TypeScript
- Homepage: https://www.npmjs.com/package/blogtraversy
- Size: 644 KB
- Stars: 31
- Watchers: 2
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: Readme.md
Awesome Lists containing this project
- jimsghstars - imabp/blogtraversy - NPM Package that fetches all your blogs from Hashnode and Medium (TypeScript)
README
Blog Traversy
Try it out LIVE! | Active Issues |
Issue Report
A tool which helps you to fetch your articles from all the publications like medium and hashnode and show it on your custom blog.
## Getting Started
#### Installation
The easiest way to install `blogtraversy` is using NPM. If you have Node.js installed, it is most likely that you have NPM installed as well
```
$ npm install blogtraversy
```
#### Usage1. Add the following to `index.js`
```js
const {getBlogs} = require('blogtraversy')```
2. A `usernames` config file is recommended. For now, you can use like this.
```js
const {getBlogs} = require('blogtraversy')const usernames = {
mediumUsername:'abirwrites',
hashnodeUsername:'imabp'
}
```3. Call GetBlogs based on your requirement passing your `usernames` config.
```js
getBlogs('all',usernames).then((res)=>console.log("All Blogs=>",res));
getBlogs('medium',usernames).then((res)=>console.log("Medium Blogs=>",res));
getBlogs('hashnode',usernames).then((res)=>console.log("Hashnode Blogs",res));
```4. The received `res` consists of the following array of objects.
```js
//getBlogs('all',usernames)
res= {
mediumArticles:[
{
url: string,
title: string,
thumbnail: string
}
],
hashnodePosts:[
{
url: string,
title: string,
thumbnail: string
}
]
}//getBlogs('medium',usernames)
res =[
{
url: string,
title: string,
thumbnail: string
}
]//getBlogs('hashnode',usernames)
res =[
{
url: string,
title: string,
thumbnail: string
}
]
```## Contribution
For contributions, please go through active [issues](https://github.com/imabp/blogtraversy/issues)