Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@arifszn/blog-js

Package Overview
Dependencies
Maintainers
1
Versions
7
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@arifszn/blog-js

Api client to get recent blog posts from popular blogging platforms,

  • 2.0.6
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
188
increased by2.73%
Maintainers
1
Weekly downloads
 
Created
Source

NPM · Report Bug · Request Feature

blog.js is a JavaScript client designed to fetch recent blog posts from popular blogging platforms such as Dev and Medium. By providing a username, users can easily retrieve and showcase their most recent posts on their website or portfolio.

Installation

Install via NPM.

npm install @arifszn/blog-js

Or install via Yarn.

yarn add @arifszn/blog-js

Usage

  • getDevPost(): Get 10 recent posts from dev.

    const { getDevPost } = require('@arifszn/blog-js');
    
    getDevPost({
      user: 'yourusername',
    }).then((res) => {
      console.log(res);
    });
    
  • getMediumPost(): Get 10 recent posts from medium.

    const { getMediumPost } = require('@arifszn/blog-js');
    
    getMediumPost({
      user: 'yourusername',
    }).then((res) => {
      console.log(res);
    });
    

Try it online.

Sample Response

[
    {
        title: "Why Enhancing Virtual Reality is Important",
        description: "Virtual reality is seen as a “fun” technology to some without much...",
        thumbnail: "https://cdn-images-1.medium.com/max/2600/0*kz30LOdXT8CyOymh",
        link: "https://medium.com/p/ac19dd21c728",
        categories: ["vr", "technology", "virtual-reality", "engineering", "artificial-intelligence"],
        publishedAt: Wed Aug 11 2021 18:43:34 GMT+0600
    },
    {
        title: "How to Get Started With Data Science: a Brief Guide",
        description: "You’ve heard about data science and machine learning, and you want to get started. Maybe you hear...",
        thumbnail: "https://cdn-images-1.medium.com/max/2600/0*Ah0vLtsvxqUvRWuS",
        link: "https://medium.com/p/88ec244f2fee",
        categories: ["beginner-coding", "data-science-training", "machine-learning-course"],
        publishedAt: Mon Jul 26 2021 22:55:26 GMT+0600
    }
]

Support

You can show your support by starring this project.

Github Star

Contribute

To contribute, see the contributing guide.

License

MIT License

Keywords

FAQs

Package last updated on 02 Mar 2024

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc