npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

social-profile-url-parser

v1.0.0

Published

A Node.js library for extracting social media profile URLs from a block of text

Downloads

24

Readme

Social Profile URL Parser

The Social Profile URL Parser is a Node.js library that allows you to extract social media profile URLs from a block of text. It is useful for situations where you have a large amount of text that contains multiple social media profile links and you want to extract and organize them in a structured way.

To use the library, you can simply pass in a string of text and the library will return an array of objects containing the social media platform name, profile URL, and username for each link found. You can also specify which platforms you want to extract links for by passing in an array of platform names.

The library supports a wide range of popular social media platforms, including Facebook, Twitter, Instagram, LinkedIn, and more. It is easy to use and can save you a lot of time and effort when working with large amounts of text containing social media profile links.

Support the project

There are many ways you can contribute to the development and improvement of the Social Profile URL Parser library. One way is by submitting code changes and bug fixes through pull requests. Your pull request will be reviewed by the project maintainers and, if accepted, will be merged into the main codebase.

Another way you can support the project is by providing feedback and suggestions. You can do this by opening an issue in the repository and describing your suggestion or problem. This allows the maintainers to track and address your feedback in a structured way.

Documentation

parser(inputText) ⇒ Array.<ParseResult>

Kind: global function
Returns: Array.<ParseResult> - an array with all the found social links

| Param | Type | Description | | --- | --- | --- | | inputText | string | the input text that will be parsed. |

Example

import { parser } from 'social-profile-url-parser';

const result = parser(`
   slack   facebook    https://www.facebook.com/slackhq/
   SlackHQ twitter     https://twitter.com/SlackHQ
`)

result === [
    {
        type: 'facebook',
        name: 'Facebook',
        username: 'slack',
        url: 'https://www.facebook.com/slackhq/'
    },
    {
       type: 'twitter',
       name: 'Twitter',
       username: 'SlackHQ',
       url: 'https://twitter.com/SlackHQ'
   }
];